Created
July 14, 2021 17:27
-
-
Save captain-yossarian/3dd1acf395f04996363db60121057b49 to your computer and use it in GitHub Desktop.
This file contains hidden or 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 fn = < | |
T extends typeof Base, | |
Instance extends InstanceType<T> | |
>(Cls: T & (new () => Instance), prop: keyof Instance, | |
) => new Cls()[prop]; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment