React · Junior · Question 66 of 75
How does React recommend reusing UI between components?
- ✓Correct answer: Composition: pass components or JSX through props and
childreninstead of inheritance - 2Class inheritance:
class Admin extends User - 3Global mixins
Explanation
Components that accept children or "slot" props (header, footer) are flexible without inheritance hierarchies. Shared logic goes into custom hooks.