Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

Yeah, currently WYSIWYG tools generate pretty terrible SVG. Sketch is especially awful, Adobe almost as bad, Inkscape the least but still somewhat bad. SVGO helps sometimes with this, but it also sometimes chews up your document and spits out an empty SVG.


To my eye Inkscape was the worst, while Illustrator and Sketch were both OK'ish. Inkscape can create pretty complex transformations on groups that are not necessary. It can also easily screw up integer coordinates and somehow add fractions to them. It's a real shame. On one occasion I rewrote an SVG file generated by Inkscape and made it literally 20 times smaller. Something like from 200k to 10k. Never used the poor thing again.


Save as "optimized svg" helps a lot as a first step.


Discovering this has helped me a lot. SVGO is great, but sometimes it breaks my SVGs. Saving as Optimized SVG from Inkscape has never caused problems and the file sizes are very close.


Yes, it is a real shame, because Inkscape in itself is really awesome. For me the best vector drawing tool available ...

But I also gave up trying to use the output for scripting. It would have been a way straight to madness ...


I read a Tweet where he claimed Affinity Designer had cleaner SVG then Illustrator . . can anyone confirm this.


I don't have Illustrator, but here are two SVGs generated by Sketch and Affinity Designer:

Sketch: http://pastebin.com/A1QRW6fT

Affinity Designer: http://pastebin.com/KxTgGQkN

I'm in the middle of building my first production app using SVG, and I've had less trouble from Affinity than Sketch.




Consider applying for YC's Summer 2026 batch! Applications are open till May 4

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: