Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Try to briefly state the difference between fulfill and resolve #42

Open
domenic opened this issue Jul 30, 2015 · 6 comments
Open

Try to briefly state the difference between fulfill and resolve #42

domenic opened this issue Jul 30, 2015 · 6 comments
Assignees

Comments

@domenic
Copy link
Member

domenic commented Jul 30, 2015

I am thinking something along the lines like "in 90% of the cases, the verb is resolve and the adjective is fulfilled. Here is why..."

@jan-ivar
Copy link

Where's the 10% where "fulfill" is used as a verb, other than by the promise implementation itself?

It doesn't help that resolved (the fate) = resolve OR reject.

Don't forget failure: Try to briefly state the difference between rejected (the state) and reject.

Btw, why this asymmetry in language in success vs. failure? Isn't it symmetrical?

@domenic
Copy link
Member Author

domenic commented Jul 30, 2015

It's not symmetrical at all, as the states vs. fates document you already found explains in great detail.

Fulfill as a verb is appropriate when the value you're resolving with is known to be a non-thenable. In such a case both fulfill and resolve are equally correct, and fulfill conveys slightly more information.

@jan-ivar
Copy link

Ah, I get the asymmetry now. There's no special treatment for thenables in reject. Thanks!

@domenic
Copy link
Member Author

domenic commented Jul 30, 2015

Cool. Yeah this was more a note to myself to expand on in a future PR, which I'll ping you to help review :)

@plinss plinss added this to the 2020-07-06-week milestone May 4, 2020
@atanassov
Copy link

@domenic given it's been a while for this issue and the spec has evolved since then to adopt and use fulfill mostly everywhere, should we close this?

@domenic
Copy link
Member Author

domenic commented Jul 6, 2020

I think people still get confused about this, but maybe it's fine to just keep pointing them to https://github.com/domenic/promises-unwrapping/blob/master/docs/states-and-fates.md.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants