Why Promise.defer() was deprecated?

I tried to search on google, github docs and posted a question on stackoverflow but I am not able to get answer that ‘what Promise.defer() was deprecated?’ Can someone please answer?

Why do you ask? Just a fan of the history of standards battles?

I see a comment on that below this post: https://stackoverflow.com/a/27889770

“It’s worth mentioning why it was removed - the promise constructor is throw safe unlike the deferred. If you throw in the scope of the promise constructor it will convert it to a rejection for you.”

See also: https://stackoverflow.com/a/34971125

2 Likes