-
-
Notifications
You must be signed in to change notification settings - Fork 26.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Document adding SVGs as React components #5147
Conversation
@mareksuscak One thing to document might be how the SVG component can accept props which are applied to the
These props are essential for my use of SVG components because I have the same SVG with different dimensions and classNames. Also when Jest snapshots are made of these SVG components in CRA2 it seems to just print their filenames.. there's no This means that the snapshots don't include these props, which (of course) means the snapshots are missing particular app states. |
@holloway Thanks for bringing it up. I think we discussed doing something like this and then forgot to fix it. Since 2.0 is not tagged at latest yet, I think it's acceptable to consider this a bugfix before final, and then insta-deprecate versions before the final one. We'll make a PR soon. |
* Document importing SVGs as React components * Update README.md
This was merged into next. Fixed via 9f7f2ab. |
oops thanks |
No worries, I was planning to update this PR later tonight but I'm glad you were able to cherry-pick the changes. Next time around, I'll make sure to allow edits from maintainers! |
* Document importing SVGs as React components * Update README.md
Preview