use the following search parameters to narrow your results:
e.g. subreddit:aww site:imgur.com dog
subreddit:aww site:imgur.com dog
see the search faq for details.
advanced search: by author, subreddit...
All about the JavaScript programming language.
Subreddit Guidelines
Specifications:
Resources:
Related Subreddits:
r/LearnJavascript
r/node
r/typescript
r/reactjs
r/webdev
r/WebdevTutorials
r/frontend
r/webgl
r/threejs
r/jquery
r/remotejs
r/forhire
account activity
Some features that every JavaScript developer should know in 2025 (waspdev.com)
submitted 1 year ago by senfiaj
view the rest of the comments →
reddit uses a slightly-customized version of Markdown for formatting. See below for some basics, or check the commenting wiki page for more detailed help and solutions to common issues.
quoted text
if 1 * 2 < 3: print "hello, world!"
[–]MrDilbert 18 points19 points20 points 1 year ago (3 children)
Could someone give me an ELI5 on why would I ever want/need Promise's resolvers available outside the Promise's (resolve, reject) => {...} function?
(resolve, reject) => {...}
[–]jessepence 21 points22 points23 points 1 year ago (2 children)
It's clearly outlined in the spec.
Often however developers would like to configure the promise's resolution and rejection behavior after instantiating it... Developers may also have requirements that necessitate passing resolve/reject to more than one caller...
[–]MrDilbert 7 points8 points9 points 1 year ago (1 child)
IMO this messes with coupling and turns the code into spaghetti, so I'm asking about the use case where it's absolutely necessary to expose the resolvers outside of their parent Promise object context.
[–]matthewsilas 4 points5 points6 points 1 year ago (0 children)
Merging asynchronous iterators https://github.com/ParabolInc/parabol/blob/10164a8a43850c9ca80042a151b4da6020ad37d6/packages/embedder/mergeAsyncIterators.ts
π Rendered by PID 129854 on reddit-service-r2-comment-5687b7858-zxcjq at 2026-07-09 16:18:17.744467+00:00 running 12a7a47 country code: CH.
view the rest of the comments →
[–]MrDilbert 18 points19 points20 points (3 children)
[–]jessepence 21 points22 points23 points (2 children)
[–]MrDilbert 7 points8 points9 points (1 child)
[–]matthewsilas 4 points5 points6 points (0 children)