You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
It seems like the plugin ignores the cwd option and starts processing all directories located in the base folder where gruntfile lies.
To verify my findings, I examined svg_sprites.js and it seems the following line (line no 66):
srcFiles = grunt.file.expand(src);
is cause of the problem. The line above ignores the cwd setting and just picks the files/patterns specified in the src parameter. In the example above for instance, it will basically scan all the directories and their sub-directories for svg files instead of limiting the search relative to 'public/assets/dist/svgs' folder.
The text was updated successfully, but these errors were encountered:
My bad, I investigated this further and seems like I ended up installing the wrong grunt-svg-sprite module. There is another grunt-svg-sprites module (notice the 's' at the end) https://www.npmjs.com/package/grunt-svg-sprites which caused the confusion. I ended up installing the wrong npm module and was wondering why the config is not working.
It seems like the plugin is ignoring the cwd option passed in via gruntfile config. So give a config like below:
It seems like the plugin ignores the cwd option and starts processing all directories located in the base folder where gruntfile lies.
To verify my findings, I examined svg_sprites.js and it seems the following line (line no 66):
is cause of the problem. The line above ignores the cwd setting and just picks the files/patterns specified in the src parameter. In the example above for instance, it will basically scan all the directories and their sub-directories for svg files instead of limiting the search relative to 'public/assets/dist/svgs' folder.
The text was updated successfully, but these errors were encountered: