- SVGO now requires Node 4 or higher.
- Changed CLI syntax to treat filenames as input, thus allowing
svgo *.svgsyntax. SVGO.optimize()now returnsPromise.- Added
dataurioption to JS API. - Added support for SVG 2
hrefattribute. cleanupIDsnow don't removes IDs if an image consists only ofdefs.- New plugin
inlineStylesfor converting styles from<style>element to attributes if possible (by @strarsis). cleanupNumericValuesnow rounds values inviewBox(by @caub).- New plugin:
removeScriptElement(disabled by default) to align withremoveStyleElement(by @pklingem). minifyStylesnow removes styles based on usage with controlling options (by @lahmatiy).- New option
exceptincleanupIDsto keep IDs (by @Velenir). - New option
forceincleanupIDsto work even if SVG containsstyleorscriptelements (by @Velenir). - Fixed arcs transforming with different signed
scaleparameters (by @JoshyPHP). - Fixed
removeUselessStrokeAndFillto check forstyleorscriptelements per file (by @caub). - New option
keepAriaAttrsinremoveUnknownsAndDefaults(by @davidtheclark). - Corrected parsing in
cleanupIDsto account animation syntax (by @caub). #ff0000now converts toredas well as#f00(by @davidleston).- Added “gray” variation to colors list per CSS Color Module Level 4 (by @ydaniv).
- Fixed error on empty files.
- A separator character in
removeAttrsnow can be changed perelemSeparatoroption (by @mikestreety). addAttributesToSVGElementnow can add values to attributes.