Rule suggestion: no unused props
OliverJAsh opened this issue · comments
Oliver Joseph Ash commented
It would be great to have a rule that errors if a component has a prop defined in its props type that is unused.
ESLint has a rule for this called react/no-unused-prop-types
.
Oliver Joseph Ash commented
Closing as I think react-unused-props-and-state
in tslint-microsoft-contrib
does this.
Kyle G commented
@OliverJAsh but it doesn't work with SFCs. Is it not something that could be added to this repo's scope, given that SFCs over Classes is clearly the direction React is moving towards.
Oliver Joseph Ash commented
Ah, you're right: microsoft/tslint-microsoft-contrib#339