Open
Description
Version
14, 18
Platform
22.2.0 Darwin Kernel arm64
Subsystem
No response
What steps will reproduce the bug?
setTimeout(() => {
console.log('calling 1st timeout')
}, 1)
setTimeout(() => {
console.log('calling 2rd timeout')
}, 0)
// in nodejs
// calling 1st timeout
// calling 2rd timeout
// however, in chrome browser
// calling 2rd timeout
// calling 1st timeout
How often does it reproduce? Is there a required condition?
No response
What is the expected behavior?
Would expect the second time to be called first
What do you see instead?
The first time out is called then the second timeout in NodeJS
Additional information
No response