postcss-normalize-whitespace
Advanced tools
Comparing version 5.0.1 to 5.0.2
@@ -49,3 +49,3 @@ "use strict"; | ||
OnceExit(css) { | ||
const cache = {}; | ||
const cache = new Map(); | ||
css.walk(node => { | ||
@@ -70,4 +70,4 @@ const { | ||
if (cache[value]) { | ||
node.value = cache[value]; | ||
if (cache.has(value)) { | ||
node.value = cache.get(value); | ||
} else { | ||
@@ -78,3 +78,3 @@ const parsed = (0, _postcssValueParser.default)(node.value); | ||
node.value = result; | ||
cache[value] = result; | ||
cache.set(value, result); | ||
} // Remove extra semicolons and whitespace before the declaration | ||
@@ -81,0 +81,0 @@ |
{ | ||
"name": "postcss-normalize-whitespace", | ||
"version": "5.0.1", | ||
"version": "5.0.2", | ||
"description": "Trim whitespace inside and around CSS rules & declarations.", | ||
@@ -10,7 +10,2 @@ "main": "dist/index.js", | ||
], | ||
"scripts": { | ||
"prebuild": "del-cli dist", | ||
"build": "cross-env BABEL_ENV=publish babel src --config-file ../../babel.config.json --out-dir dist --ignore \"**/__tests__/\"", | ||
"prepublish": "yarn build" | ||
}, | ||
"keywords": [ | ||
@@ -30,3 +25,3 @@ "css", | ||
"dependencies": { | ||
"postcss-value-parser": "^4.1.0" | ||
"postcss-value-parser": "^4.2.0" | ||
}, | ||
@@ -45,3 +40,7 @@ "bugs": { | ||
}, | ||
"gitHead": "28c247175032fa03f04911cde56ad82d74d211cc" | ||
} | ||
"scripts": { | ||
"prebuild": "rimraf dist", | ||
"build": "babel src --config-file ../../babel.config.json --out-dir dist --ignore \"**/__tests__/\"" | ||
}, | ||
"readme": "# [postcss][postcss]-normalize-whitespace\n\n> Normalize whitespace with PostCSS.\n\n## Install\n\nWith [npm](https://npmjs.org/package/postcss-normalize-whitespace) do:\n\n```\nnpm install postcss-normalize-whitespace --save\n```\n\n## Example\n\n### Input\n\n```css\nh1{\n width: calc(10px - ( 100px / var(--test) )) \n}\n```\n\n### Output\n\n```css\nh1{\n width: calc(10px - 100px / var(--test))\n}\n``` \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\nMIT © [Ben Briggs](http://beneb.info)\n\n[postcss]: https://github.com/postcss/postcss\n" | ||
} |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
6404
4
Updatedpostcss-value-parser@^4.2.0