Last active
April 11, 2017 11:07
-
-
Save Willmo36/aaca949b6ae731db6f7b8373f4026102 to your computer and use it in GitHub Desktop.
TypeScript HoC props interface
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
export default function hoc<T extends HoCProps>(WrappedComponent): React.ComponentClass<T> { | |
return class extends React.Component<T, null> { | |
... | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment