-
Notifications
You must be signed in to change notification settings - Fork 37
Output is SVG source on Windows #12
Comments
Has anyone found a workaround for this? |
Not sure if you are using 'svgmin' but I found 'svgmin' was messing it up for me. If i move it after 'svg2png' in my Gruntfile.js in grunt.registerTask(), then it generates the png properly, didn't need the xml declaration either. |
Another workaround for you need to run svgmin before svg2png (as if you are using grunticon), you can simply disable the removal of the xml declaration in svgmin:
Of course, ideally, svg2min could support files without the xml declaration. |
Worth mentioning... the latest version of Illustrator (I'm on v19.2.0) has a new 'Export... SVG' dialog which seems to automatically strip the declaration. grunt-svg2png still needs this declaration in order to output a rasterized SVG graphic (rather than rasterized lines of XML code). Grrrrr. |
On Windows 7, the output is not the image, but an image of the source code for the SVG.
This only occurs if the SVG does not have an XML declaration. If I add
<?xml version="1.0"?>
to the document, it will work correctly.SVG Source:
The text was updated successfully, but these errors were encountered: