|
|
|
|
|
by wonderlg
2136 days ago
|
|
With your library one has to write types twice. I understand that it’s not TypeScript’s job at the moment, but it’d be great to enable runtime checks with the flick of a switch without typing extra code. function upper(s: string) {
return s.toUpperCase();
}
This function could have a nice implicit TypeError instead of “undefined is not a function” |
|