DEV Community

loading...

Discussion on: How to create an extremely reusable Icon component with react-svg

Collapse
vtrpldn profile image
Vitor Paladini Author

react-svg lets you dynamically import SVG files so you can spec the SVG file name in the Icon name prop and it'll do the rest :)

Collapse
z2lai profile image
z2lai

Oh right, that's an excellent benefit. Now the post title makes sense :D. Thanks a lot!

Thread Thread
vtrpldn profile image
Vitor Paladini Author

Glad I could help!

Forem Open with the Forem app