🚀 Big News: Socket Acquires Coana to Bring Reachability Analysis to Every Appsec Team.Learn more
Socket
Sign inDemoInstall
Socket

cssnano

Package Overview
Dependencies
Maintainers
1
Versions
148
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

cssnano - npm Package Compare versions

Comparing version

to
2.0.1

9

CHANGELOG.md

@@ -0,1 +1,10 @@

# current
---
# 2.0.1
* Add `postcss-plugin` keyword to package.json.
* Wraps all core processors with the PostCSS 4.1 plugin API.
# 2.0.0

@@ -2,0 +11,0 @@

7

lib/borderOptimiser.js
'use strict';
var hasLength = require('./util/hasLength');
var list = require('postcss').list;
var postcss = require('postcss');
var list = postcss.list;
var removeSelf = require('./util/removeSelf');

@@ -38,6 +39,6 @@ var canMergeProperties = require('./util/canMergeProperties');

module.exports = function () {
module.exports = postcss.plugin('cssnano-border-optimiser', function () {
return function (css) {
css.eachRule(borderOptimiser);
};
};
});
'use strict';
var TRBLOptimiser = require('./trblCache');
var postcss = require('postcss');

@@ -18,3 +19,3 @@ var collapsableTRBLProps = [

module.exports = function () {
module.exports = postcss.plugin('cssnano-core', function () {
return function (css) {

@@ -58,2 +59,2 @@ css.eachDecl(function (declaration) {

};
};
});
'use strict';
var balancedMatch = require('balanced-match');
var list = require('postcss').list;
var postcss = require('postcss');
var list = postcss.list;

@@ -14,6 +15,6 @@ function filterOptimiser(rule) {

module.exports = function () {
module.exports = postcss.plugin('cssnano-filter-optimiser', function () {
return function (css) {
css.eachDecl(/filter/, filterOptimiser);
};
};
});
'use strict';
var list = require('postcss').list;
var postcss = require('postcss');
var list = postcss.list;
var cssList = require('css-list');

@@ -44,3 +45,3 @@ var balancedMatch = require('balanced-match');

module.exports = function () {
module.exports = postcss.plugin('cssnano-function-optimiser', function () {
return function (css) {

@@ -51,2 +52,2 @@ functions.forEach(function (fn) {

};
};
});

@@ -8,2 +8,3 @@ 'use strict';

var canMergeProperties = require('./util/canMergeProperties');
var postcss = require('postcss');

@@ -86,3 +87,3 @@ var trbl = ['top', 'right', 'bottom', 'left'];

module.exports = function () {
module.exports = postcss.plugin('cssnano-longhand-optimiser', function () {
return function (css) {

@@ -93,2 +94,2 @@ css.eachRule(mergeLonghand('margin'));

};
};
});
{
"name": "cssnano",
"version": "2.0.0",
"version": "2.0.1",
"description": "A modular minifier, built on top of the PostCSS ecosystem.",

@@ -19,6 +19,8 @@ "main": "index.js",

"css",
"compress",
"minify",
"optimise",
"optimisation",
"postcss"
"postcss",
"postcss-plugin"
],

@@ -25,0 +27,0 @@ "license": "MIT",