Where'd Promise#done go?

Domenic Denicola domenic at domenicdenicola.com
Tue Jun 18 20:03:50 PDT 2013


From: es-discuss-bounces at mozilla.org [mailto:es-discuss-bounces at mozilla.org] On Behalf Of Kevin Smith

> To this end, in my own promise implementation I use a form of "fail soon", like so:

It sounds like this does not support handling rejections in an event loop turn after they are generated, e.g. it would disallow

```js
var rejected = Promise.reject(new Error("bad news!"));
var fulfilled = Promise.resolve(5);

fulfilled.then(() => {
    rejected.catch(err => console.error(err));
});
```

Is that correct?


More information about the es-discuss mailing list