Created
January 27, 2020 06:19
-
-
Save tmanOC/6dac334bd65f43e46e77c99e24764b59 to your computer and use it in GitHub Desktop.
Structure of a simple promise handler
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
methodThatReturnsAPromise().then(result => { | |
handleResult(result) | |
}).catch(err => { | |
handleAnyExceptions(err) | |
}) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment