Pomax / js-svg-path

A parser that turns SVG path strings into a JS object you can mess with.
63 stars 4 forks source link

Switcheroo bug when parsing horizontal line with offset #3

Open sjovanovic opened 4 years ago

sjovanovic commented 4 years ago

When parsing horizontal line and there's offset set (case when xoffset != yoffset) results in weird output because yoffset is added to the x coordinate instead of xoffset.

https://github.com/Pomax/js-svg-path/blob/b6c0e5c566fd3853348f912f85e688838300593d/svg-parser.js#L66