Uh oh!
There was an error while loading. Please reload this page.
Remove PropTypes from production build (#209) - #3818
Conversation
gaearon
commented
Jan 17, 2018
gaearon
commented
Jan 17, 2018
Hmm. I feel like that ESLint rule is too restrictive. It should be perfectly okay to use another component's Button.propTypes={
...Touchable.propTypes,color: PropTypes.string}The message is also not friendly: It should say something like Can you follow up with |
* Remove PropTypes from production build (react#209) * Added react/forbid-foreign-prop-types rule to eslint config * Removed react/forbid-foreign-prop-types rule from eslint config
csantos1113
commented
Nov 1, 2018
I'm too late on this thread. but what about the scenario that @gaearon mentioned about: ? |
iansu
commented
Nov 1, 2018
I made a PR to |
csantos1113
commented
Nov 1, 2018
@iansu - thanks for the quick reply. Why about this case: |
iansu
commented
Nov 2, 2018
I'm not sure why you'd be getting the warning in that case. This would need to be addressed in |
Apply
babel-plugin-transform-react-remove-prop-typeswhen building for production.Closes#209