React · Junior · Question 63 of 75
What does <Button {...props} /> do?
- ✓Correct answer: Passes every property of
propsas separate props toButton - 2Passes a single prop named
props - 3Copies
Button's props intoprops
Explanation
Spreading is convenient for wrappers, but forwards everything, including props the child doesn't expect. Prefer explicit props where possible.