-
Notifications
You must be signed in to change notification settings - Fork 13.2k
Description
In Overloads section in https://www.typescriptlang.org/docs/handbook/functions.html mentioned that overload is supported, but that about notification in case if arguments is wrong?
According doc's example we have next error message: "Argument of type 'passedArgumentType' is not assignable to parameter of type 'expectedArgumentType'"
The message will be more informative if whole list of overloads will be displayed.
I would expect next message: "Argument of type '""' is not assignable to parameter of list of types 'number' or '{suit: string; card: number; }[]'"
In this case developer can see all list of available types for overloads what will reduce the search of all supported types.
Please let me know is my proposual correct and can it be implemented?
