postcss-reduce-initial
Advanced tools
Comparing version
{ | ||
"name": "postcss-reduce-initial", | ||
"version": "5.0.2", | ||
"version": "5.0.3", | ||
"description": "Reduce initial definitions to the actual initial value, where possible.", | ||
"main": "dist/index.js", | ||
"main": "src/index.js", | ||
"files": [ | ||
"data", | ||
"dist/index.js", | ||
"src/index.js", | ||
"LICENSE-MIT" | ||
], | ||
"scripts": { | ||
"acquire": "node ./src/script/acquire.mjs", | ||
"prebuild": "rimraf dist", | ||
"build": "babel src --config-file ../../babel.config.json --out-dir dist --ignore \"**/__tests__\"", | ||
"prepare": "yarn build" | ||
}, | ||
"keywords": [ | ||
@@ -45,3 +39,7 @@ "css", | ||
"postcss": "^8.2.15" | ||
} | ||
} | ||
}, | ||
"scripts": { | ||
"acquire": "node ./src/script/acquire.mjs" | ||
}, | ||
"readme": "# [postcss][postcss]-reduce-initial\n\n> Reduce `initial` definitions to the _actual_ initial value, where possible.\n\n## Install\n\nWith [npm](https://npmjs.org/package/postcss-reduce-initial) do:\n\n```\nnpm install postcss-reduce-initial --save\n```\n\n## Examples\n\nSee the [data](data) for more conversions. This data is courtesy\nof Mozilla.\n\n### Convert `initial` values\n\nWhen the `initial` keyword is longer than the property value, it will\nbe converted:\n\n#### Input\n\n```css\nh1 {\n min-width: initial;\n}\n```\n\n#### Output\n\n```css\nh1 {\n min-width: 0;\n}\n```\n\n### Convert values back to `initial`\n\nWhen the `initial` value is smaller than the property value, it will\nbe converted:\n\n#### Input\n\n```css\nh1 {\n transform-box: border-box;\n}\n```\n\n#### Output\n\n```css\nh1 {\n transform-box: initial;\n}\n```\n\nThis conversion is only applied when you supply a browsers list that all support\nthe `initial` keyword; it's worth noting that Internet Explorer has no support.\n\n## API\n\n### reduceInitial([options])\n\n#### options\n\n##### ignore\n\nType: `Array<String>`\nDefault: `undefined`\n\nIt contains the Array of properties that will be ignored while reducing its value to initial.\nExample : `{ ignore : [\"min-height\"] }`\n\n## Usage\n\nSee the [PostCSS documentation](https://github.com/postcss/postcss#usage) for\nexamples for your environment.\n\n## Contributors\n\nSee [CONTRIBUTORS.md](https://github.com/cssnano/cssnano/blob/master/CONTRIBUTORS.md).\n\n## License\n\n[Template:CSSData] by Mozilla Contributors is licensed under [CC-BY-SA 2.5].\n\n[template:cssdata]: https://developer.mozilla.org/en-US/docs/Template:CSSData\n[cc-by-sa 2.5]: http://creativecommons.org/licenses/by-sa/2.5/\n\nMIT © [Ben Briggs](http://beneb.info)\n\n[postcss]: https://github.com/postcss/postcss\n" | ||
} |
17370
9.01%392
1.03%