svgo
4.1.0 · 24 Aug 2026MIT52.3M / weekRepositoryHomepagenpmAtom feed
2.8.4 is the newest release of 2.x.
In short
1 fixed1 internal
Security
3 advisories affect 2.8.2; 2.8.4 fixes them
- HighSVGO: removeScripts allows executable links through namespace and control-character bypassesGHSA-w27v-7q3p-w38r · 8 Sep 2026Fixed in 2.8.4
- HighSVGO removeScripts plugin leaves some executable scripts intactGHSA-2p49-hgcm-8545 · 21 Jul 2026Fixed in 2.8.3
- ModerateSVGO: removeScripts incompletely sanitizes executable HTML in SVG foreignObject elementsGHSA-4vpr-x523-8j87 · 8 Sep 2026Fixed in 2.8.4
Release note
This is effectively just a re-release of SVGO v2.8.1, but with *.test.js files omitted. It seems something was wrong with the configuration in the v2.8.0 tag and I hadn't noticed it included a few extra files. :sweat_smile:
We'll deprecate v2.8.1, and I'll include the change log here.
What's Changed
Bug Fixes
No longer throws error when encountering comments in DTD.
Metrics
Before and after of the browser bundle of each respective version:
| v2.8.0 | v2.8.2 | Delta | |
|---|---|---|---|
| svgo.browser.js | 587.2 kB | 589.2 kB | ⬆️ 2 kB |
Support
SVGO v2 is not officially supported, please consider upgrading to SVGO v4 instead. We've backported this fix as there are security implications, but there is no commitment to do this for more complex changes in future.
Consider reading our Migration Guide from v2 to v3 and Migration Guide from v3 to v4 which should ease the process.
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.