-
Notifications
You must be signed in to change notification settings - Fork 11
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
SVG-File-Error #13
Comments
hey @lukasoppermann, I don't know grunt-svgstore, so please tell me if that also does optimize the SVG files?! Please try disabling SVG optimization altogether first, then try tweaking the SVGO settings (plugins). I know there are some edge cases where SVGO cripples files, but this is not an iconizr bug. If SVGO turns out to be the cause, and if you've got some time, you could try to reproduce an isolated case with SVGO only and file an issue there?! Pls let me know ... Cheers, |
Hey, I do not think it does optimization, I will try this and get back to you, thanks. Okay, I just checked if I use |
@lukasoppermann which optimizer are you using with I'm using SVGO without it all the time and I'd say it's a bug over in this project. :) |
Hi @stefanjudis, I didn't say it's necessarily a bug. I just made the experience that some SVGO plugins are too agressive for some SVG files, resulting in crippled files. @lukasoppermann Please make sure to use Thanks guys, cheers, |
👍 Please report progess. ;) |
Sure! :) |
That was just a typo on github, not in the GruntFile though. I sent you the file via email, hope you have more luck, thanks. |
Note to myself (and for the sake of completeness) — this is the image in question: <?xml version="1.0" encoding="utf-8"?>
<!-- Generator: Adobe Illustrator 17.0.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) -->
<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1 Tiny//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11-tiny.dtd">
<svg version="1.1" baseProfile="tiny" id="Layer_1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink"
x="0px" y="0px" width="512px" height="512px" viewBox="0 0 512 512" xml:space="preserve">
<path d="M253.875,102.4C94.822,102.4,0,250.982,0,250.982S96.947,409.6,256,409.6s256-160,256-160S412.928,102.4,253.875,102.4z
M254.848,345.6c-49.485,0-89.6-40.115-89.6-89.6s40.115-89.6,89.6-89.6s89.6,40.115,89.6,89.6S304.333,345.6,254.848,345.6z"/>
</svg> |
Hey @lukasoppermann (and @stefanjudis), I finally found the time to work on this specific issue. As expected, this seems to be an issue with an overly aggressive SVGO plugin. Please try this as configuration with the given sample file: {
/* ... */
// cleanwith: 'svgo',
cleanconfig: {
plugins: [
{convertPathData: false}
]
}
} The sample SVG file should renders just fine then, right? If you find the time, please head over to SVGO and file an issue there (possibly referencing this one here). Thanks & cheers, |
Sorry, forgot to mention: Additionally, there has been a bug in the svg-sprite sources that prevented the SVGO plugin configuration to be properly merged with the default values. This will be fixed with the next release. |
Awesome, thank you. 👍 |
Fixed as of release 17c721a |
Hey I noticed that some icons are broken like this:
I do not get the problem working with https://github.com/FWeinb/grunt-svgstore with the same icons. This plugin saves every in a group -tag. Maybe this would solve it?
The text was updated successfully, but these errors were encountered: