Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- let prom = new Promise(res => {
- console.log('A')
- setTimeout(res,1000)
- })
- prom.then(res => {
- console.log('B')
- })
- console.log('C')
- // A
- // C
- // B
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement