Created
November 19, 2021 10:16
-
-
Save Misaka-0x447f/3ae6e0beaec7e08be24a445dd136ac35 to your computer and use it in GitHub Desktop.
Overriding arrow function
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const m: { | |
(a: string): void; | |
(b: number): void | |
} = (c: string | number) => {} | |
// editor now knows first use name a, second use name b. | |
m('1') | |
m(1) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment