This repository has been archived by the owner on Jan 26, 2022. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 27
Aggregate exception type vs. array of exceptions #11
Comments
What would the |
Good question. Probably something generic, and unspecified, like all other |
I guess what I mean is, what does |
i'd assume the constructor would take two arguments - |
For reference, my |
Another reason why I would prefer |
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
The readme currently indicates that the rejection value would be an array of exceptions. Although this is not the worst thing, it definitely goes against prevailing practice to only throw exception types, and seems like it would play badly with lots of ecosystem code that assumes
Error
subclasses. For example, test frameworks or debugging tooling.I have always hoped that the proposal for
Promise.any
would also introduce a newAggregateError
type that contains a pointer to an array of exceptions.The text was updated successfully, but these errors were encountered: