Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@svgr/plugin-svgo

Package Overview
Dependencies
Maintainers
1
Versions
25
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@svgr/plugin-svgo - npm Package Compare versions

Comparing version 5.4.0 to 5.5.0

16

CHANGELOG.md

@@ -6,2 +6,18 @@ # Change Log

# [5.5.0](https://github.com/gregberge/svgr/tree/master/packages/plugin-svgo/compare/v5.4.0...v5.5.0) (2020-11-15)
### Features
* **svgo:** add .svgorc.js config file support ([#451](https://github.com/gregberge/svgr/tree/master/packages/plugin-svgo/issues/451)) ([8049b1a](https://github.com/gregberge/svgr/tree/master/packages/plugin-svgo/commit/8049b1a63603672096892b6ab3d303580c2f303f)), closes [#412](https://github.com/gregberge/svgr/tree/master/packages/plugin-svgo/issues/412)
### Performance Improvements
* replace merge-deep with smaller deepmerge ([#463](https://github.com/gregberge/svgr/tree/master/packages/plugin-svgo/issues/463)) ([1f015eb](https://github.com/gregberge/svgr/tree/master/packages/plugin-svgo/commit/1f015eb16fca093a08b012236dc83623f7bcce55))
# [5.4.0](https://github.com/gregberge/svgr/tree/master/packages/plugin-svgo/compare/v5.3.1...v5.4.0) (2020-04-27)

@@ -8,0 +24,0 @@

10

lib/config.js

@@ -9,8 +9,6 @@ "use strict";

var _mergeDeep = _interopRequireDefault(require("merge-deep"));
var _deepmerge = _interopRequireDefault(require("deepmerge"));
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
function _extends() { _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
function getFilePath(state) {

@@ -56,3 +54,3 @@ return state.filePath || process.cwd();

function mergePlugins(configs) {
const plugins = configs.reduce((merged, config) => (0, _mergeDeep.default)(merged, ...extractPlugins(config)), {});
const plugins = configs.reduce((merged, config) => _deepmerge.default.all([merged, ...extractPlugins(config)]), {});
return Object.keys(plugins).reduce((array, key) => {

@@ -68,5 +66,5 @@ array.push({

const plugins = mergePlugins(configs);
return _extends({}, (0, _mergeDeep.default)(...configs), {
return { ..._deepmerge.default.all(configs.filter(Boolean)),
plugins
});
};
}

2

lib/index.js

@@ -16,3 +16,3 @@ "use strict";

const explorer = (0, _cosmiconfig.cosmiconfigSync)('svgo', {
searchPlaces: ['package.json', '.svgorc', '.svgorc.json', '.svgorc.yaml', '.svgorc.yml', 'svgo.config.js', '.svgo.yml'],
searchPlaces: ['package.json', '.svgorc', '.svgorc.js', '.svgorc.json', '.svgorc.yaml', '.svgorc.yml', 'svgo.config.js', '.svgo.yml'],
transform: result => result && result.config,

@@ -19,0 +19,0 @@ cache: true

{
"name": "@svgr/plugin-svgo",
"description": "Optimize SVG",
"version": "5.4.0",
"version": "5.5.0",
"main": "lib/index.js",

@@ -29,7 +29,7 @@ "repository": "https://github.com/gregberge/svgr/tree/master/packages/plugin-svgo",

"dependencies": {
"cosmiconfig": "^6.0.0",
"merge-deep": "^3.0.2",
"cosmiconfig": "^7.0.0",
"deepmerge": "^4.2.2",
"svgo": "^1.2.2"
},
"gitHead": "e9c9d2fbfbce7a6879c90cd8522101caf2406d42"
"gitHead": "b5920550bd966f876cb65c5e23af180461e5aa23"
}
SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc