JSFiddle - React, Tailwind, and code Playground

JavaScript

setTimeout(() => console.log('timer'), 0);
console.log('sync code 1');
Promise.resolve('promise').then(x => console.log(x));
console.log('sync code 2');