Better HN
top
new
best
ask
show
jobs
Log in
Sign up
Better HN
Comment
by
Bahamut
· 11y ago · 0 comments
Or better, Promise.reject
Comments
[–]
loganfsmyth
11y ago
Both are useful, but I'd hesitate to call it better. What makes you say it is better?
[–]
Bahamut
OP
11y ago
It makes explicit that the intention that a promise should be rejected, as opposed to a throw where one might reasonably expect an exception of some sort.