Packages

svgo

4.1.0 · 24 Aug 2026MIT52.3M / weekRepositoryHomepagenpmAtom feed

Your version

2.8.0

2 Nov 2021Where it was published

2.8.4 is the newest release of 2.x.

In short

4 new4 changed

Security

4 advisories affect 2.8.0; 2.8.4 fixes them

Release note

If you enjoy SVGO and would like to support our work, consider sponsoring us directly via our OpenCollective.

Join us in our discord

Features and bug fixes

  • Added --no-color flag for testing purposes but you may find it useful (#1588)

  • Handle url() in style attributes properly (#1592)

  • removeXMLNS plugin now removes xmlns:xlink attribute (#1508)

  • Load .cjs configuration only with require to fix segfaults in linux (#1605)

Refactorings

  • Simplified and covered with types svg stringifier (#1593)

  • Migrated to visitor api and covered with types removeEmptyAttrs plugin (#1594)

  • Migrated to visitor api and covered with types inlineStyles plugin (#1601)

  • Migrated to picocolors (#1606)

DX

I found some users are trying to enable plugins which are not part of default preset, for example

{
  name: 'preset-default',
  params: {
    overrides: {
      cleanupListOfValues: true
    }
  }
}

To fix this I made docs more concrete about plugin (5165ccb)
and introduced a warning when true is specified in overrides (cb7e9be).
Please give us feedback if you still have issues.

A whole project to check? Paste its package.json in the dependency check: every deprecated, outdated or vulnerable dependency, with what to upgrade to. Free, no account.