{"p2":{"x":141,"y":85},"mode":"line","p1":{"x":34,"y":44}}
becomes M 34 44 L 141 85
and of course also has ways to express curved paths, etc.interesting. I didn't know that. I tried googling to find out what parts are not implemented but couldn't find anything (admittedly not a long search).
Do you have more information you can point me to?
A line is just <line x1=10 y1=20 x2=30 y2=40>:
https://jsfiddle.net/46q5srhg/
It can also be used inside markdown, which supports it out of the box because SVG is part of HTML:
https://markdownpastebin.com/?id=7d7b2f9dc65448ddbd7d1576676...
Examples of both are at [0] (C++ based parser, you'd also need to write some bindings for lua) and [1] (Lua based parser for a subset of the format, abandoned for almost a decade).
There are times when using an external dependency might be a good idea, but a text-based file format that describes lines and can be implemented in a few lines of code is not one.
Do you know if there is some formal way to 'declare' such a subset (something to do with XML/namespaces maybe?), or if there's any existing standard "simple SVG" format that someone has already defined? Obviously I could just informally stick to a subset by avoiding whatever features I don't want to use, but I think it would be useful to have a formally defined subset, and to be able to scan an SVG to detect if it's within the subset or not.
https://en.wikipedia.org/wiki/Brand_Indicators_for_Message_I...