SVG is an over-romanticised format.
Support for logic makes it a major XSS vector, XML makes it inefficient, and the path langage makes it unreadable.
SVG is an over-romanticised format.
Support for logic makes it a major XSS vector, XML makes it inefficient, and the path langage makes it unreadable.
at least this part seems over-the top criticism :-)
Anything that can capture free-form graphical information will be unreadable. You could represent paths with points but that would make it more inefficient.
The thing to keep in mind too is that because it fell out of favor the standard has not really evolved.
Individually the XML and the path format are “fine”, the problem is that they’re both in the same file format.
> Anything that can capture free-form graphical information will be unreadable.
It’s not the question of being freeform, it’s the weird-ass single-letter command names in an attribute string.
In an XML document which is otherwise self-descripting.
> In an XML document which is otherwise self-descripting.
This is an odd plaint. M/m is for move, L/l is for line-to, C/c is for curve-to, V/v and H/h are for vertical and horizontal lines respectively, and svgo might throw some 's' curves in there. It's the best of both worlds, giving excellent compression while remaining human readable enough for a novice to manipulate geometry by just messing about.
It could be readable or efficient, and either would be fine, but it’s neither.