Inconsistency between console and query

Not sure if this is a bug or whether I am just misunderstanding something.

See attached image, just a basic bit of js to get the start and end of the month (ignore line 1).

I was using the console to check my code but it kept printing 2024-01-01 for range end which is incorrect. So then I got the query to return and realised that it was printing the correct result.

Any idea what's going on here?

you may want to use moment(rangeEnd).format('YYYY-MM-DD') in the console output.

That does indeed solve it, thank you ScottR

1 Like