I am defining a new Date object: const date = new Date(2020, 09, 11); The documentation says that the default time for the constructor is: hours : 0, minutes : 0, seconds : 0... etc. However, the result I get is:
const date = new Date(2020, 09, 11);
console.log(date);
2020-10-11T07:00:00.000Z
Why is the hour 7?
When I put the following into the console:
const date2 = new Date(2020, 09, 11, -7)
console.log(date2)
2020-10-11T00:00:00.000Z
I'm at a bit of a loss here.