Skip to content

Instantly share code, notes, and snippets.

@rpl
Last active November 21, 2016 18:59
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 1 You must be signed in to fork a gist
  • Save rpl/b4379a17d59c36fea6c3db524b07b02b to your computer and use it in GitHub Desktop.
Save rpl/b4379a17d59c36fea6c3db524b07b02b to your computer and use it in GitHub Desktop.
small promise example
function () {
if (...) {
return Promise.resolve();
}
const isDonePromise = doSomethingAsync().then(() => {
});
...
return isDonePromise;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment