Last active
November 3, 2020 07:32
-
-
Save pritidesai/452eaa373e00b4013bcf771280d97aa1 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
new Promise((resolve, reject) => { | |
let a = 50 / 2 // Task A | |
resolve(a) | |
}).then((result) => { | |
console.log('In TaskB - TaskA finished with result', result); // Task B | |
}).finally((result) => { // list of finally tasks | |
console.log('In finally - TaskA finished with result', result); | |
console.log('Continue running rest of the finally tasks'); | |
}); | |
Author
pritidesai
commented
Nov 3, 2020
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment