We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
React.FC
See facebook/create-react-app#8177
All components use React.FC in NRN, I liked it because it made explicit the component were functional, but it has a few drawbacks.
Planning on changing that for all components.
The text was updated successfully, but these errors were encountered:
Alternative: VoidFunctionComponent from React.
VoidFunctionComponent
Example:
type Props = { children: React.ReactElement | string; containerStyle?: CSSStyles; } & Partial<TooltipProps>; const HelpTooltip: VoidFunctionComponent<Props> = (props): JSX.Element => { ... }
https://github.com/DefinitelyTyped/DefinitelyTyped/blob/master/types/react/index.d.ts#L549
DefinitelyTyped/DefinitelyTyped#34237 (comment)
Sorry, something went wrong.
Vadorequest
No branches or pull requests
See facebook/create-react-app#8177
All components use React.FC in NRN, I liked it because it made explicit the component were functional, but it has a few drawbacks.
Planning on changing that for all components.
The text was updated successfully, but these errors were encountered: