en.javascript.info/8-async/02-promise-basics/01-re-resolve/task.md
Ilya Kantor 75895f44b8 up
2017-04-22 15:31:56 +03:00

15 lines
209 B
Markdown

# Re-resolve a promise?
What's the output of the code below?
```js
let promise = new Promise(function(resolve, reject) {
resolve(1);
setTimeout(() => resolve(2), 1000);
});
promise.then(alert);
```