setTimeout(), setInterval(), and requestAnimationFrame()
In what order will the code execute?
setTimeout(() => {
// Code A
}, 0);
Promise.resolve().then(() => {
// Code B
});
// Code C
setTimeout(() => {
// Code A
}, 0);
Promise.resolve().then(() => {
// Code B
});
// Code C