Last active
April 7, 2019 22:58
-
-
Save khaosdoctor/90c989674c98a1d63acb9a5ce1809ae7 to your computer and use it in GitHub Desktop.
This file contains hidden or 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
const p = new Promise((resolve, reject) => { | |
setTimeout(() => resolve('yay'), 5000) | |
}) | |
// Ambos os callbacks estão ligados a p | |
p.then((res) => {}, (rej) => {}) | |
// Isto aqui é a mesma coisa | |
new Promise((resolve, reject) => {}) | |
.then((res) => {}, (rej) => {}) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment