Games Node.js Loop Quest The VIP line
A tick inside a tick
A nextTick queues another nextTick while a promise is waiting.
process.nextTick(() => { console.log('tick 1'); process.nextTick(() => console.log('tick 2'));});Promise.resolve().then(() => console.log('promise'));1. Predict the output
Tap the lines in the order you think they print.
- 1…
- 2…
- 3…