You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Having the ability to add a title prop is a very useful feature. We also use fairly strict linting rules which require us to add propTypes on any React component. It would be great when using --title-prop to have the ability to add the corresponding propType.
I understand that one could use --template for this, but since --title-prop exists, we may as well complete that feature.
Motivation
This would make the component pass when eslint-ing with strict rules.
Example
svgr --title-prop --title-prop-type string --title-defafult-prop "" would generate something like
🚀 Feature Proposal
Having the ability to add a title prop is a very useful feature. We also use fairly strict linting rules which require us to add propTypes on any React component. It would be great when using
--title-prop
to have the ability to add the corresponding propType.I understand that one could use
--template
for this, but since--title-prop
exists, we may as well complete that feature.Motivation
This would make the component pass when eslint-ing with strict rules.
Example
svgr --title-prop --title-prop-type string --title-defafult-prop ""
would generate something likePitch
It would be a good addition to the
--title-prop
I am happy to try submitting a patch if this is approved!
The text was updated successfully, but these errors were encountered: