Open jonambas opened 6 years ago
I'm not sure if this can be done due to limitation of svgo to be used at the browser side. See the below issue. Looks like it is closed but not yet implemented.
Sorry for the late update.
So I tried and it is indeed too much work or almost impossible to integrate SVGO. Those are the bad news, but, we are already doing some optimizations that come for free with the svg-to-jsx
package and I think it would be trivial to add more if only svg-to-jsx
accepted some kind of plugins.
I think it should be possible to run svgo (or parts of it) in the browser, check https://github.com/svg/svgo/issues/1050 and https://github.com/jakearchibald/svgomg/issues/88#issuecomment-290986043
Thoughts on integrating a tool such as svgo? Just an idea.
SVG files from most editors contain a lot of useless code - comments, metadata, hidden elements, etc. UI showcasing its capabilities: https://jakearchibald.github.io/svgomg
I also think it'd be useful to paste markup, in addition to uploading an svg file. 😊