Id's conflict if SVG's optimized and inlined

 The online SVG optimizer, 'svgomg', shortens id's to the same letters which conflict if the SVG's are inlined.


I solved this by turning off the 'Clean up IDs' option.


I use the optimizer at: 'jakearchibald.github.io/svgomg/'. The W3C HTML validator points out the conflicts.


The Node.js tool that is used has a prefix option or plugin to solve this problem.


The SVG's at 'openclipart.org' by regular contributors are not shrunk that much by the optimizer. One SVG got bigger after being optimized. Another SVG was dramatically smaller after being optimized.


There are more tips at: bbingo.xyz/techtips/

Comments

Popular posts from this blog

webkit-tap-highlight-color in CSS

Steve Jobs quotes