Unable to change SVG icons color in react
I have downloaded svg files and added fill = "currentColor" to each individual . THen i created a file to export these svg, so i can use it in other components. THis is where the issue happens, i cant change the color via CSS , i even added !important, still its showing default black color. ANyone knows how to fix it?
3 Replies
the svg need to be an inline svg element not a img tag with svg file set as src.
also it's fill not color
i used fill it wasnt working.
if i paste svg , my code becomes even more messier.
its working