skip to Main Content

Reactjs – React FC Component – Display Name

I want to create a packages like react-bootstrap. <Card> <Card.Title>Hello</Card.Title> </Card> I wish to create like below. But I couldn't able to do. <MyCustomComponent> <MyCustomComponent.Header> Header goes here </MyCustomComponent.Header> </MyCustomComponent> interface Props { children?: React.ReactNode | React.ReactNode[] } export const…

VIEW QUESTION
Back To Top
Search