3 ms·
background-image: url("./icon.svg?main-color=ff0000") And serve icon.svg dynamically. As others have mentioned, only for colors, there are easier ways. But u
by emilsedgh 10y ago
background-image: url("./icon.svg?main-color=ff0000")
And serve icon.svg dynamically.
As others have mentioned, only for colors, there are easier ways.
But using this technique you can do anything.
- amelius 10y agoYes, good idea. Just wondering, is there a standard way of doing this? And do vector drawing programs support parameterization?
- marcosdumay 10y agoJust be wary of code injection. It is XML, so it should be easy on any framework.