Closed maple3142 closed 2 years ago
Note that the configuration documentation states:
The default preset of plugins is fully overridden if the
plugins
field is specified. Usepreset-default
plugin to customize plugins options.
So the default example may want to include that (or at least a note) so that folks don't think they're only altering one plugin when they're actually removing all of the default plugins.
Maybe this example:
svgo({
plugins: [
{
name: "preset-default",
params: { overrides: { removeViewBox: false, removeUselessDefs: false } },
},
],
})
So that other can find this when searching GitHub, the error you see when you're using the older SVGO config is
Plugin name should be specified
The usage are changed after #354: https://github.com/imagemin/imagemin-svgo/commit/43888a0389bdd4c8e7790d5c2cea25d497a561ea