Games Node.js Loop Quest The VIP line
Ticks first, as a group
nextTick and promise calls, written alternately.
process.nextTick(() => console.log('t1'));Promise.resolve().then(() => console.log('p1'));process.nextTick(() => console.log('t2'));Promise.resolve().then(() => console.log('p2'));1. Predict the output
Tap the lines in the order you think they print.
- 1…
- 2…
- 3…
- 4…