You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Feb 11, 2025. It is now read-only.
We have the useUnknownInCatchVariables setting enabled in our tsconfig (it’s part of the strict family).
But it only applies to try {} catch(e) {} blocks, not to Promise.catch (which is still typed as any). So it causes a kinda weird inconsistency in how exceptions are handled and makes it harder to be type-safe.
There is a typescript issue to update the Promise.catch() behaviour here microsoft/TypeScript#45602, but it is yet to be implemented.
This was a recommendation from @dglsparsons:
The text was updated successfully, but these errors were encountered: