From a32d26e9addaeda773330e827182e555ac6d7da0 Mon Sep 17 00:00:00 2001 From: Seth Falco Date: Thu, 5 Oct 2023 19:22:45 +0100 Subject: [PATCH] fix(removeScriptElement): remove link anchors with scripts --- README.md | 2 +- plugins/removeScriptElement.js | 30 +++++++++++++++++++++++-- test/plugins/removeScriptElement.02.svg | 15 +++++++++++++ test/plugins/removeScriptElement.03.svg | 17 ++++++++++++++ 4 files changed, 61 insertions(+), 3 deletions(-) create mode 100644 test/plugins/removeScriptElement.02.svg create mode 100644 test/plugins/removeScriptElement.03.svg diff --git a/README.md b/README.md index 4296cae1e..64f8aa854 100644 --- a/README.md +++ b/README.md @@ -198,7 +198,7 @@ const config = await loadConfig(configFile, cwd); | [removeNonInheritableGroupAttrs](https://github.com/svg/svgo/blob/main/plugins/removeNonInheritableGroupAttrs.js) | remove non-inheritable group's "presentation" attributes | Yes | | [removeOffCanvasPaths](https://github.com/svg/svgo/blob/main/plugins/removeOffCanvasPaths.js) | removes elements that are drawn outside of the viewbox | | | [removeRasterImages](https://github.com/svg/svgo/blob/main/plugins/removeRasterImages.js) | remove raster images | | -| [removeScriptElement](https://github.com/svg/svgo/blob/main/plugins/removeScriptElement.js) | remove `