change_extendDefaultPlugins_to_preset_default - #12
Conversation
|
Is there a timeline for when this will be merged? |
|
@danielstgt Hi can you review and merge this pr? Would appreciate it! 🙂 |
|
Until @danielstgt gets time to merge this in, I've created a fork which can be installed with NPM here @luckyzeno @medeiroz @unre4l |
|
I swithced to @georgehanson package. Problem was svg were not scaling correcty and the reason was, that svgo was removing svg viewBoxes. I had to change svgoSettings from this: to this |
tonila
left a comment
There was a problem hiding this comment.
It seems, option definitions are not working as expected.
Docs say, that removeViewBox and removeTitle are enabled by default and removeDimensions is not.
So to remove title and dimensions and preserve viewBox, configuration that worked for me was:
{
loader: 'svgo-loader',
options: {
plugins: [
{
name: 'preset-default',
params: {
overrides: {
removeViewBox: false
}
},
},
'removeDimensions'
],
}
}
It seems this is not possible to configure with current implemention. Or is it?
|
Hi @luckyzeno, and sorry for the very late reply on this, thanks a lot for taking the time to open the PR! 🙏 In the meantime this change has been implemented directly in To be transparent about why I'm closing this rather than merging it: the PR in its current form wouldn't have worked correctly. It passed Closing as no longer needed, but really appreciate you flagging the deprecation, it's what got this fixed. |
"extendDefaultPlugins" utility is deprecated. So I changed it to preset_default plugin