postcss-will-change
Advanced tools
Comparing version 2.0.0 to 3.0.0
# Change Log | ||
This project adheres to [Semantic Versioning](http://semver.org/). | ||
## 3.0 | ||
* Use PostCSS 7. | ||
* Remove Node.js 4 support. | ||
## 2.0 | ||
@@ -5,0 +9,0 @@ * Use PostCSS 6. |
22
index.js
@@ -1,13 +0,13 @@ | ||
var postcss = require('postcss'); | ||
var postcss = require('postcss') | ||
module.exports = postcss.plugin('postcss-will-change', function () { | ||
return function (css) { | ||
css.walkDecls('will-change', function (decl) { | ||
var already = decl.parent.some(function (i) { | ||
return i.type === 'decl' && i.prop === 'backface-visibility'; | ||
}); | ||
if ( already ) return; | ||
decl.cloneBefore({ prop: 'backface-visibility', value: 'hidden' }); | ||
}); | ||
}; | ||
}); | ||
return function (css) { | ||
css.walkDecls('will-change', function (decl) { | ||
var already = decl.parent.some(function (i) { | ||
return i.type === 'decl' && i.prop === 'backface-visibility' | ||
}) | ||
if (already) return | ||
decl.cloneBefore({ prop: 'backface-visibility', value: 'hidden' }) | ||
}) | ||
} | ||
}) |
{ | ||
"name": "postcss-will-change", | ||
"version": "2.0.0", | ||
"version": "3.0.0", | ||
"description": "PostCSS plugin to insert 3D hack before will-change property", | ||
@@ -14,36 +14,6 @@ "keywords": [ | ||
"license": "MIT", | ||
"repository": "postcss/postcss-will-change.git", | ||
"repository": "postcss/postcss-will-change", | ||
"dependencies": { | ||
"postcss": "^6.0.1" | ||
}, | ||
"devDependencies": { | ||
"eslint": "^3.19.0", | ||
"eslint-config-postcss": "^2.0.2", | ||
"jest": "^20.0.0", | ||
"lint-staged": "^3.4.1", | ||
"pre-commit": "^1.2.2" | ||
}, | ||
"scripts": { | ||
"lint-staged": "lint-staged", | ||
"test": "jest && eslint *.js" | ||
}, | ||
"jest": { | ||
"coverageThreshold": { | ||
"global": { | ||
"statements": 100 | ||
} | ||
} | ||
}, | ||
"eslintConfig": { | ||
"extends": "eslint-config-postcss/es5", | ||
"env": { | ||
"jest": true | ||
} | ||
}, | ||
"lint-staged": { | ||
"*.js": "eslint" | ||
}, | ||
"pre-commit": [ | ||
"lint-staged" | ||
] | ||
"postcss": "^7.0.2" | ||
} | ||
} |
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
No repository
Supply chain riskPackage does not have a linked source code repository. Without this field, a package will have no reference to the location of the source code use to generate the package.
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
No repository
Supply chain riskPackage does not have a linked source code repository. Without this field, a package will have no reference to the location of the source code use to generate the package.
Found 1 instance in 1 package
0
3580
+ Addedpicocolors@0.2.1(transitive)
+ Addedpostcss@7.0.39(transitive)
- Removedansi-styles@3.2.1(transitive)
- Removedchalk@2.4.2(transitive)
- Removedcolor-convert@1.9.3(transitive)
- Removedcolor-name@1.1.3(transitive)
- Removedescape-string-regexp@1.0.5(transitive)
- Removedhas-flag@3.0.0(transitive)
- Removedpostcss@6.0.23(transitive)
- Removedsupports-color@5.5.0(transitive)
Updatedpostcss@^7.0.2