Closed
Description
One thing we've noticed tends to make code a little opaque is when we destructure the entire props for a sub-component:
function MyComponent(props) {
return <MySubComponent {...props} />
}
It would be great to have an eslint rule to force expanding individual props that should be passed down:
function MyComponent(props) {
return <MySubComponent one_prop={props.one_prop} two_prop={props.two_prop} />
}