motion
Version:
motion - moving development forward
100 lines (99 loc) • 12 kB
JSON
{
"_args": [
[
"svgo@https://registry.npmjs.org/svgo/-/svgo-0.6.1.tgz",
"/Users/nw/flint/packages/flint"
]
],
"_from": "svgo@>=0.6.1 <0.7.0",
"_id": "svgo@0.6.1",
"_inCache": true,
"_location": "/svgo",
"_phantomChildren": {},
"_requested": {
"name": "svgo",
"raw": "svgo@https://registry.npmjs.org/svgo/-/svgo-0.6.1.tgz",
"rawSpec": "https://registry.npmjs.org/svgo/-/svgo-0.6.1.tgz",
"scope": null,
"spec": "https://registry.npmjs.org/svgo/-/svgo-0.6.1.tgz",
"type": "remote"
},
"_requiredBy": [
"/postcss-svgo"
],
"_resolved": "https://registry.npmjs.org/svgo/-/svgo-0.6.1.tgz",
"_shasum": "b9dd8d450660ca5f88b22271fbdc8b2a966637a9",
"_shrinkwrap": null,
"_spec": "svgo@https://registry.npmjs.org/svgo/-/svgo-0.6.1.tgz",
"_where": "/Users/nw/flint/packages/flint",
"author": {
"email": "kir@soulshine.in",
"name": "Kir Belevich",
"url": "https://github.com/deepsweet"
},
"bin": {
"svgo": "./bin/svgo"
},
"bugs": {
"email": "kir@soulshine.in",
"url": "https://github.com/svg/svgo/issues"
},
"contributors": [
{
"name": "Sergey Belov",
"email": "peimei@ya.ru",
"url": "http://github.com/arikon"
},
{
"name": "Lev Solntsev",
"email": "lev.sun@ya.ru",
"url": "http://github.com/GreLI"
}
],
"dependencies": {
"coa": "~1.0.1",
"colors": "~1.1.2",
"csso": "~1.4.2",
"js-yaml": "~3.4.3",
"mkdirp": "~0.5.1",
"sax": "~1.1.4",
"whet.extend": "~0.9.9"
},
"description": "Nodejs-based tool for optimizing SVG vector graphics files",
"devDependencies": {
"coveralls": "~2.11.4",
"istanbul": "~0.4.0",
"mocha": "~2.3.4",
"mocha-istanbul": "~0.2.0",
"should": "7.1.1"
},
"directories": {
"bin": "./bin",
"example": "./examples",
"lib": "./lib"
},
"engines": {
"node": ">=0.10.0"
},
"homepage": "https://github.com/svg/svgo",
"keywords": [
"minify",
"optimize",
"svg",
"svgo"
],
"license": "MIT",
"main": "./lib/svgo.js",
"name": "svgo",
"optionalDependencies": {},
"readme": "**english** | [русский](https://github.com/svg/svgo/blob/master/README.ru.md)\n- - -\n\n<img src=\"https://svg.github.io/svgo-logo.svg\" width=\"200\" height=\"200\" alt=\"logo\"/>\n\n## SVGO [](https://npmjs.org/package/svgo) [](https://gemnasium.com/svg/svgo) [](https://travis-ci.org/svg/svgo) [](https://coveralls.io/r/svg/svgo?branch=master)\n\n**SVG O**ptimizer is a Nodejs-based tool for optimizing SVG vector graphics files.\n\n\n## Why?\n\nSVG files, especially exported from various editors, usually contains a lot of redundant and useless information such as editor metadata, comments, hidden elements, default or non-optimal values and other stuff that can be safely removed or converted without affecting SVG rendering result.\n\n## What it can do\n\nSVGO has a plugin-based architecture, so almost every optimization is a separate plugin.\n\nToday we have:\n\n* [ [ cleanupAttrs](https://github.com/svg/svgo/blob/master/plugins/cleanupAttrs.js) ] cleanup attributes from newlines, trailing and repeating spaces\n* [ [ removeDoctype](https://github.com/svg/svgo/blob/master/plugins/removeDoctype.js) ] remove doctype declaration\n* [ [ removeXMLProcInst](https://github.com/svg/svgo/blob/master/plugins/removeXMLProcInst.js) ] remove XML processing instructions\n* [ [ removeComments](https://github.com/svg/svgo/blob/master/plugins/removeComments.js) ] remove comments\n* [ [ removeMetadata](https://github.com/svg/svgo/blob/master/plugins/removeMetadata.js) ] remove `<metadata>`\n* [ [ removeTitle](https://github.com/svg/svgo/blob/master/plugins/removeTitle.js) ] remove `<title>` (disabled by default)\n* [ [ removeDesc](https://github.com/svg/svgo/blob/master/plugins/removeDesc.js) ] remove `<desc>` (only non-meaningful by default)\n* [ [ removeUselessDefs](https://github.com/svg/svgo/blob/master/plugins/removeUselessDefs.js) ] remove elements of `<defs>` without `id`\n* [ [ removeEditorsNSData](https://github.com/svg/svgo/blob/master/plugins/removeEditorsNSData.js) ] remove editors namespaces, elements and attributes\n* [ [ removeEmptyAttrs](https://github.com/svg/svgo/blob/master/plugins/removeEmptyAttrs.js) ] remove empty attributes\n* [ [ removeHiddenElems](https://github.com/svg/svgo/blob/master/plugins/removeHiddenElems.js) ] remove hidden elements\n* [ [ removeEmptyText](https://github.com/svg/svgo/blob/master/plugins/removeEmptyText.js) ] remove empty Text elements\n* [ [ removeEmptyContainers](https://github.com/svg/svgo/blob/master/plugins/removeEmptyContainers.js) ] remove empty Container elements\n* [ [ removeViewBox](https://github.com/svg/svgo/blob/master/plugins/removeViewBox.js) ] remove `viewBox` attribute when possible (disabled by default)\n* [ [ cleanUpEnableBackground](https://github.com/svg/svgo/blob/master/plugins/cleanupEnableBackground.js) ] remove or cleanup `enable-background` attribute when possible\n* [ [ minifyStyles](https://github.com/svg/svgo/blob/master/plugins/minifyStyles.js) ] minify `<style>` elements content with [CSSO](https://github.com/css/csso)\n* [ [ convertStyleToAttrs](https://github.com/svg/svgo/blob/master/plugins/convertStyleToAttrs.js) ] convert styles into attributes\n* [ [ convertColors](https://github.com/svg/svgo/blob/master/plugins/convertColors.js) ] convert colors (from `rgb()` to `#rrggbb`, from `#rrggbb` to `#rgb`)\n* [ [ convertPathData](https://github.com/svg/svgo/blob/master/plugins/convertPathData.js) ] convert Path data to relative or absolute whichever is shorter, convert one segment to another, trim useless delimiters, smart rounding and much more\n* [ [ convertTransform](https://github.com/svg/svgo/blob/master/plugins/convertTransform.js) ] collapse multiple transforms into one, convert matrices to the short aliases and much more\n* [ [ removeUnknownsAndDefaults](https://github.com/svg/svgo/blob/master/plugins/removeUnknownsAndDefaults.js) ] remove unknown elements content and attributes, remove attrs with default values\n* [ [ removeNonInheritableGroupAttrs](https://github.com/svg/svgo/blob/master/plugins/removeNonInheritableGroupAttrs.js) ] remove non-inheritable group's \"presentation\" attributes\n* [ [ removeUselessStrokeAndFill](https://github.com/svg/svgo/blob/master/plugins/removeUselessStrokeAndFill.js) ] remove useless stroke and fill attrs\n* [ [ removeUnusedNS](https://github.com/svg/svgo/blob/master/plugins/removeUnusedNS.js) ] remove unused namespaces declaration\n* [ [ cleanupIDs](https://github.com/svg/svgo/blob/master/plugins/cleanupIDs.js) ] remove unused and minify used IDs\n* [ [ cleanupNumericValues](https://github.com/svg/svgo/blob/master/plugins/cleanupNumericValues.js) ] round numeric values to the fixed precision, remove default 'px' units\n* [ [ moveElemsAttrsToGroup](https://github.com/svg/svgo/blob/master/plugins/moveElemsAttrsToGroup.js) ] move elements attributes to the existing group wrapper\n* [ [ moveGroupAttrsToElems](https://github.com/svg/svgo/blob/master/plugins/moveGroupAttrsToElems.js) ] move some group attributes to the content elements\n* [ [ collapseGroups](https://github.com/svg/svgo/blob/master/plugins/collapseGroups.js) ] collapse useless groups\n* [ [ removeRasterImages](https://github.com/svg/svgo/blob/master/plugins/removeRasterImages.js) ] remove raster images (disabled by default)\n* [ [ mergePaths](https://github.com/svg/svgo/blob/master/plugins/mergePaths.js) ] merge multiple Paths into one\n* [ [ convertShapeToPath](https://github.com/svg/svgo/blob/master/plugins/convertShapeToPath.js) ] convert some basic shapes to path\n* [ [ sortAttrs](https://github.com/svg/svgo/blob/master/plugins/sortAttrs.js) ] sort element attributes for epic readability (disabled by default)\n* [ [ transformsWithOnePath](https://github.com/svg/svgo/blob/master/plugins/transformsWithOnePath.js) ] apply transforms, crop by real width, center vertical alignment and resize SVG with one Path inside (disabled by default)\n* [ [ removeDimensions](https://github.com/svg/svgo/blob/master/plugins/removeDimensions.js) ] remove width/height attributes if viewBox is present (disabled by default)\n* [ [ removeAttrs](https://github.com/svg/svgo/blob/master/plugins/removeAttrs.js) ] remove attributes by pattern (disabled by default)\n* [ [ addClassesToSVGElement](https://github.com/svg/svgo/blob/master/plugins/addClassesToSVGElement.js) ] add classnames to an outer `<svg>` element (disabled by default)\n* [ [ removeStyleElement](https://github.com/svg/svgo/blob/master/plugins/removeStyleElement.js) ] remove `<style>` elements (disabled by default)\n\nWant to know how it works and how to write your own plugin? [Of course you want to](https://github.com/svg/svgo/blob/master/docs/how-it-works/en.md).\n\n\n## How to use\n\n```sh\n$ [sudo] npm install -g svgo\n```\n\n```\nUsage:\n svgo [OPTIONS] [ARGS]\n\nOptions:\n -h, --help : Help\n -v, --version : Version\n -i INPUT, --input=INPUT : Input file, \"-\" for STDIN\n -s STRING, --string=STRING : Input SVG data string\n -f FOLDER, --folder=FOLDER : Input folder, optimize and rewrite all *.svg files\n -o OUTPUT, --output=OUTPUT : Output file or folder (by default the same as the input), \"-\" for STDOUT\n -p PRECISION, --precision=PRECISION : Set number of digits in the fractional part, overrides plugins params\n --config=CONFIG : Config file to extend or replace default\n --disable=DISABLE : Disable plugin by name\n --enable=ENABLE : Enable plugin by name\n --datauri=DATAURI : Output as Data URI string (base64, URI encoded or unencoded)\n -q, --quiet : Only output error messages, not regular status messages\n --pretty : Make SVG pretty printed\n --show-plugins : Show available plugins and exit\n\nArguments:\n INPUT : Alias to --input\n OUTPUT : Alias to --output\n```\n\n* with files:\n\n $ svgo test.svg\n\n or:\n\n $ svgo test.svg test.min.svg\n\n* with STDIN / STDOUT:\n\n $ cat test.svg | svgo -i - -o - > test.min.svg\n\n* with folder\n\n $ svgo -f ../path/to/folder/with/svg/files\n\n or:\n\n $ svgo -f ../path/to/folder/with/svg/files -o ../path/to/folder/with/svg/output\n\n* with strings:\n\n $ svgo -s '<svg version=\"1.1\">test</svg>' -o test.min.svg\n\n or even with Data URI base64:\n\n $ svgo -s 'data:image/svg+xml;base64,…' -o test.min.svg\n\n* with SVGZ:\n\n from `.svgz` to `.svg`:\n\n $ gunzip -c test.svgz | svgo -i - -o test.min.svg\n\n from `.svg` to `.svgz`:\n\n $ svgo test.svg -o - | gzip -cfq9 > test.svgz\n\n* with GUI – [svgo-gui](https://github.com/svg/svgo-gui)\n* as a web app - [SVGOMG](https://jakearchibald.github.io/svgomg/)\n* as a Nodejs module – [examples](https://github.com/svg/svgo/tree/master/examples)\n* as a Grunt task – [grunt-svgmin](https://github.com/sindresorhus/grunt-svgmin)\n* as a Gulp task – [gulp-svgmin](https://github.com/ben-eb/gulp-svgmin)\n* as a Mimosa module – [mimosa-minify-svg](https://github.com/dbashford/mimosa-minify-svg)\n* as an OSX Folder Action – [svgo-osx-folder-action](https://github.com/svg/svgo-osx-folder-action)\n* as a webpack loader – [image-webpack-loader](https://github.com/tcoopman/image-webpack-loader)\n\n## Donate\n\nBTC `1zVZYqRSzQ4aaL27rp3PLwFFSXpfs5H8r`\n\n## License and copyrights\n\nThis software is released under the terms of the [MIT license](https://github.com/svg/svgo/blob/master/LICENSE).\n\nLogo by [Yegor Bolshakov](http://xizzzy.ru/).\n",
"readmeFilename": "README.md",
"repository": {
"type": "git",
"url": "git://github.com/svg/svgo.git"
},
"scripts": {
"test": "make test"
},
"version": "0.6.1"
}