I'd like to create 2 react components <Father /> and <Child /> and force the developer to use Child only inside Father:
<Father>
<!-- should be fine -->
<Child />
</Father>
<!-- should throw an error -->
<Child />
Is there any way to do it? If so, what's the syntax I should use?