/
package.json
executable file
·46 lines (46 loc) · 4.63 KB
/
package.json
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
{
"name": "clean-css",
"author": {
"name": "Jakub Pawlowicz",
"email": "jakub@goalsmashers.com",
"url": "http://twitter.com/GoalSmashers"
},
"description": "A well-tested CSS minifier",
"keywords": [
"css",
"minifier"
],
"homepage": "https://github.com/GoalSmashers/clean-css",
"repository": {
"type": "git",
"url": "https://github.com/GoalSmashers/clean-css.git"
},
"version": "0.10.2",
"main": "index.js",
"bin": {
"cleancss": "./bin/cleancss"
},
"scripts": {
"bench": "node test/bench.js",
"check": "jshint .",
"prepublish": "jshint .",
"test": "vows"
},
"dependencies": {
"commander": "1.1.x"
},
"devDependencies": {
"vows": "0.7.x",
"jshint": "0.9.x"
},
"engines": {
"node": ">=0.6.0"
},
"readme": "[![build status](https://secure.travis-ci.org/GoalSmashers/clean-css.png)](http://travis-ci.org/GoalSmashers/clean-css)\n\n## What is clean-css?\n\nClean-css is a [node.js](http://nodejs.org/) library for minifying CSS files.\nIt does the same job as YUI Compressor's CSS minifier, but much faster thanks\nto many speed optimizations and node.js' V8 engine.\n\n\n## Usage\n\n### What are the requirements?\n\n```\nnode 0.6.0+ on UN*X (fully tested on OS X 10.6+ and CentOS)\nnode 0.8.0+ on Windows\n```\n\n### How to install clean-css?\n\n```\nnpm install clean-css\n```\n\n### How to use clean-css CLI?\n\nClean-css accepts the following command line arguments (please make sure you use `<source-file>` as the \nvery last argument to avoid potential issues):\n\n```\ncleancss [options] <source-file>\n```\n* `-h`, `--help` output usage information\n* `-v`, `--version` output the version number\n* `-e`, `--remove-empty` Remove empty declarations (e.g. `a{}`)\n* `-b`, `--keep-line-breaks` Keep line breaks\n* `--s0` Remove all special comments (i.e. `/*! special comment */`)\n* `--s1` Remove all special comments but the first one\n* `-o`, `--output [output-file]` Use [output-file] as output instead of stdout\n\n#### Examples:\n\nTo minify a **public.css** file into **public-min.css** do:\n\n```\ncleancss -o public-min.css public.css\n```\n\nTo minify the same **public.css** into the standard output skip the `-o` parameter:\n\n```\ncleancss public.css\n```\n\nMore likely you would like to concatenate a couple of files.\nIf you are on a Unix-like system:\n\n```\ncat one.css two.css three.css | cleancss -o merged-and-minified.css\n```\n\nOn Windows:\n\n```\ntype one.css two.css three.css | cleancss -o merged-and-minified.css\n```\n\nOr even gzip the result at once:\n\n```\ncat one.css two.css three.css | cleancss | gzip -9 -c > merged-minified-and-gzipped.css.gz\n```\n\n### How to use clean-css programmatically?\n\n```js\nvar cleanCSS = require('clean-css');\nvar source = \"a{font-weight:bold;}\";\nvar minimized = cleanCSS.process(source);\n```\n\nProcess method accepts a hash as a second parameter, i.e.,\n`cleanCSS.process(source, options)` with the following options available:\n\n* `keepSpecialComments` - `*` for keeping all (default), `1` for keeping first one, `0` for removing all\n* `keepBreaks` - whether to keep line breaks (default is false)\n* `removeEmpty` - whether to remove empty elements (default is false)\n* `debug` - turns on debug mode measuring time spent on cleaning up\n (run `npm run bench` to see example)\n\n### What are the clean-css' dev commands?\n\nFirst clone the source, then run:\n\n* `npm run bench` for clean-css benchmarks (see test/bench.js for details)\n* `npm run check` to check JS sources with [JSHint](https://github.com/jshint/jshint/)\n* `npm test` for the test suite\n\n### How do you preserve a comment block?\n\nUse the `/*!` notation instead of the standard one `/*`:\n\n```css\n/*!\n Important comments included in minified output.\n*/\n```\n\n\n## Acknowledgments\n\n* Vincent Voyer ([@vvo](https://github.com/vvo)) for a patch with better\n empty element regex and for inspiring us to do many performance improvements\n in 0.4 release.\n* Isaac ([@facelessuser](https://github.com/facelessuser)) for pointing out\n a flaw in clean-css' stateless mode.\n* Jan Michael Alonzo ([@jmalonzo](https://github.com/jmalonzo)) for a patch\n removing node's old 'sys' package.\n* [@XhmikosR](https://github.com/XhmikosR) for suggesting new features\n (option to remove special comments and strip out URLs quotation) and pointing\n out numerous improvements (JSHint, media queries).\n\n## License\n\nClean-css is released under the [MIT License](http://opensource.org/licenses/MIT).\n",
"readmeFilename": "README.md",
"bugs": {
"url": "https://github.com/GoalSmashers/clean-css/issues"
},
"_id": "clean-css@0.10.2",
"_from": "clean-css@~0.10.0"
}