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

RFE: Clarify intent re resolve(promise) #95

Open
FGasper opened this issue Dec 19, 2019 · 1 comment
Open

RFE: Clarify intent re resolve(promise) #95

FGasper opened this issue Dec 19, 2019 · 1 comment

Comments

@FGasper
Copy link

FGasper commented Dec 19, 2019

Hello,

I see the following paragraph in the test suite docs:

Note that the tests will never pass a promise or a thenable as a resolution. That means that we never use the promise- or thenable-accepting forms of the resolve operation directly, and instead only use the direct fulfillment operation, since fulfill and resolve are equivalent when not given a thenable.

What is the intended behaviour, though, when a promise is given directly to deferred.resolve()? Should the original promise’s resolution be that of the “subpromise”, or should the subpromise itself be the original promise’s resolution?

Thank you!

@FGasper
Copy link
Author

FGasper commented Dec 19, 2019

I note that ES6’s promise specification indicates explicitly that in such cases the “subpromise”’s resolution value is also the original’s resolution value.

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

1 participant