express-cdn
Advanced tools
Comparing version 0.1.4 to 0.1.6
@@ -23,4 +23,3 @@ // express-cdn | ||
, _ = require('underscore') | ||
, jsp = require('uglify-js').parser | ||
, pro = require('uglify-js').uglify | ||
, uglify = require('uglify-js') | ||
, spawn = require('child_process').spawn | ||
@@ -167,6 +166,6 @@ , optipngPath = require('optipng-bin').path | ||
if (results instanceof Array) results = results.join("\n"); | ||
var ast = jsp.parse(results); | ||
ast = pro.ast_mangle(ast); | ||
ast = pro.ast_squeeze(ast); | ||
var final_code = pro.gen_code(ast); | ||
var final_code = uglify.minify(results,{ | ||
fromString: true | ||
, output : { comments : '/license/' } | ||
}).code; | ||
zlib.gzip(final_code, function(err, buffer) { | ||
@@ -200,3 +199,3 @@ if (err) throwError(err); | ||
// Process images | ||
minify = minify.replace(/(?:background\-image|background|content)\:[^;]*\)/g, function (rootMatch) { | ||
minify = minify.replace(/(?:background\-image|background|content|border\-image)\:[^;\n]*\)/g, function (rootMatch) { | ||
@@ -203,0 +202,0 @@ //Multiples Images URL per background |
{ | ||
"name": "express-cdn", | ||
"description": "Node.js module for delivering optimized, minified, mangled, gzipped, and CDN-hosted assets in Express using S3 and CloudFront.", | ||
"version": "0.1.4", | ||
"version": "0.1.6", | ||
"author": { | ||
@@ -40,2 +40,10 @@ "name": "Nick Baugh", | ||
"email": "elad.benisrael@gmail.com" | ||
}, | ||
{ | ||
"name": "Mateusz Wielgos", | ||
"email": "wielgosm@gmail.com" | ||
}, | ||
{ | ||
"name": "Aleksey Smolenchuk", | ||
"email": "lxe@lxe.co" | ||
} | ||
@@ -80,3 +88,3 @@ ], | ||
"request": "~2.16.6", | ||
"uglify-js": "~1.3.5", | ||
"uglify-js": "~2.4.3", | ||
"underscore.string": "~2.3.1" | ||
@@ -89,3 +97,3 @@ }, | ||
"async": "~0.2.9", | ||
"uglify-js": "~1.3.5", | ||
"uglify-js": "~2.4.3", | ||
"optipng-bin": "~0.3", | ||
@@ -92,0 +100,0 @@ "jpegtran-bin": "~0.1.4", |
@@ -368,2 +368,8 @@ [![Gittip](http://badgr.co/gittip/niftylettuce.png)](https://www.gittip.com/niftylettuce/) | ||
* 0.1.6 - Fixed extracting CSS border-image resources and image snot followed by `;` in CSS (by @lxe) | ||
* 0.1.5 - Preserved license comments with UglifyJS version 2.0 (by @mateusz-) | ||
* 0.1.4 - Added case insensitive usage of `cdn` or `CDN` (by @leostera) | ||
* 0.1.3 - Explicity set `x-amz-acl` to `public-read`. | ||
@@ -414,2 +420,3 @@ | ||
* Elad Ben-Israel <elad.benisrael@gmail.com> | ||
* Aleksey Smolenchuk <lxe@lxe.co> | ||
@@ -416,0 +423,0 @@ |
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
100204
451
607
+ Addedamdefine@1.0.1(transitive)
+ Addedcamelcase@1.2.1(transitive)
+ Addeddecamelize@1.2.0(transitive)
+ Addedsource-map@0.1.34(transitive)
+ Addeduglify-js@2.4.24(transitive)
+ Addeduglify-to-browserify@1.0.2(transitive)
+ Addedwindow-size@0.1.0(transitive)
+ Addedwordwrap@0.0.2(transitive)
+ Addedyargs@3.5.4(transitive)
- Removeduglify-js@1.3.5(transitive)
Updateduglify-js@~2.4.3