Skip to content

Commit

Permalink
docs: remove usage of deprecated extendDefaultPlugins in doc (#319)
Browse files Browse the repository at this point in the history
  • Loading branch information
mdarveau authored Sep 5, 2022
1 parent 901517d commit 02839ee
Showing 1 changed file with 13 additions and 9 deletions.
22 changes: 13 additions & 9 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,6 @@ For `imagemin-svgo` v9.0.0+ need use svgo [configuration](https://github.com/svg

```js
const ImageMinimizerPlugin = require("image-minimizer-webpack-plugin");
const { extendDefaultPlugins } = require("svgo");

module.exports = {
module: {
Expand Down Expand Up @@ -119,18 +118,23 @@ module.exports = {
[
"svgo",
{
plugins: extendDefaultPlugins([
{
name: "removeViewBox",
active: false,
},
plugins: [
{
name: "addAttributesToSVGElement",
name: "preset-default",
params: {
attributes: [{ xmlns: "http://www.w3.org/2000/svg" }],
overrides: {
removeViewBox: false,
addAttributesToSVGElement: {
params: {
attributes: [
{ xmlns: "http://www.w3.org/2000/svg" },
],
},
},
},
},
},
]),
],
},
],
],
Expand Down

0 comments on commit 02839ee

Please sign in to comment.