This my index.js file:
console.log(
"new Date(2022, 2, 23, 0, 0, 0, 0)",
new Date(2022, 2, 23, 0, 0, 0, 0)
);
console.log(
"new Date(2022, 4, 16, 0, 0, 0, 0)",
new Date(2022, 4, 16, 0, 0, 0, 0)
);
And the output I'm getting is:
new Date(2022, 2, 23, 0, 0, 0, 0) 2022-03-23T00:00:00.000Z
new Date(2022, 4, 16, 0, 0, 0, 0) 2022-05-15T23:00:00.000Z
I'm expecting to see the ...05-16T00... in the second, but somehow that is not that case.
I'm running node.js version 16.14.2, I tried to upgrade to 16.15.0. Also I tried 17.9.0 and 18.2.0
When I tried to put the code above to the browser or tried the https://codesandbox.io/, I've got what I'm expecting.