minimize
Advanced tools
Comparing version 2.0.0 to 2.1.0
@@ -282,3 +282,3 @@ 'use strict'; | ||
if (cfg.ssi && ~element.data.indexOf('#include')) return io(); | ||
if (cfg.ssi && ~element.data.indexOf('#')) return io(); | ||
if (cfg.conditionals && (~element.data.indexOf('[if') | ||
@@ -285,0 +285,0 @@ || ~element.data.indexOf('<![endif'))) return io(); |
@@ -10,3 +10,3 @@ 'use strict'; | ||
, html = require('htmlparser2') | ||
, uuid = require('node-uuid') | ||
, uuid = require('uuid') | ||
, emits = require('emits') | ||
@@ -13,0 +13,0 @@ , async = require('async') |
{ | ||
"name": "minimize", | ||
"version": "2.0.0", | ||
"version": "2.1.0", | ||
"description": "Minimize HTML", | ||
@@ -16,17 +16,17 @@ "main": "./lib/minimize", | ||
"dependencies": { | ||
"argh": "~0.1.4", | ||
"async": "~2.0.0-rc.6", | ||
"cli-color": "~1.1.0", | ||
"diagnostics": "~1.0.1", | ||
"emits": "~3.0.0", | ||
"htmlparser2": "~3.9.1", | ||
"node-uuid": "~1.4.7" | ||
"argh": "^0.1.4", | ||
"async": "^2.1.5", | ||
"cli-color": "^1.2.0", | ||
"diagnostics": "^1.1.0", | ||
"emits": "^3.0.0", | ||
"htmlparser2": "^3.9.2", | ||
"uuid": "^3.0.0" | ||
}, | ||
"devDependencies": { | ||
"chai": "~3.5.0", | ||
"istanbul": "~0.4.3", | ||
"mocha": "~2.5.3", | ||
"pre-commit": "~1.1.3", | ||
"sinon": "~1.17.4", | ||
"sinon-chai": "~2.8.0" | ||
"chai": "^3.5.0", | ||
"istanbul": "^0.4.5", | ||
"mocha": "^3.2.0", | ||
"pre-commit": "^1.2.2", | ||
"sinon": "^1.17.7", | ||
"sinon-chai": "^2.8.0" | ||
}, | ||
@@ -33,0 +33,0 @@ "repository": "git@github.com:Moveo/minimize.git", |
@@ -6,2 +6,3 @@ { | ||
"ssimulti": "<!--#include virtual=\"/head.html\" --><!--#include virtual=\"/header.html\" -->\n <div class=\"slide nodejs\">\n <h3>100% Node.js</h3>\n <p>\n We are Node.js experts and the first hosting platform to build\n our full stack in node. We understand your node application\n better than anyone.\n </p>\n </div>\n\n ", | ||
"ssicommands": "<!--#echo var=\"name\" default=\"no\" -->\n <div class=\"slide nodejs\">\n <h3>100% Node.js</h3>\n <p>\n We are Node.js experts and the first hosting platform to build\n our full stack in node. We understand your node application\n better than anyone.\n </p>\n </div>\n\n ", | ||
"ie": "<!--[if IE 6]>Special instructions for IE 6 here<![endif]-->\n <div class=\"slide nodejs\">\n <h3>100% Node.js</h3>\n </div>", | ||
@@ -8,0 +9,0 @@ "iemulti": "<!--[if IE 10]>Special instructions for IE 10 here<![endif]--><!--[if IE 6]>Special instructions for IE 6 here<![endif]-->\n <div class=\"slide nodejs\">\n <h3>100% Node.js</h3>\n </div>", |
@@ -141,2 +141,10 @@ 'use strict'; | ||
it('should be configurable to retain server side commands', function (done) { | ||
var commentable = new Minimize({ ssi: true }); | ||
commentable.parse(html.ssicommands, function (error, result) { | ||
expect(result).to.equal('<!--#echo var=\"name\" default=\"no\"--><div class=\"slide nodejs\"><h3>100% Node.js</h3><p>We are Node.js experts and the first hosting platform to build our full stack in node. We understand your node application better than anyone.</p></div>'); | ||
done(); | ||
}); | ||
}); | ||
it('should be configurable to retain conditional IE comments', function (done) { | ||
@@ -143,0 +151,0 @@ var commentable = new Minimize({ conditionals: true }); |
89392
1835
+ Addeduuid@^3.0.0
+ Addedasync@2.6.4(transitive)
+ Addedcli-color@1.4.0(transitive)
+ Addedcolor@3.2.1(transitive)
+ Addedcolor-convert@1.9.3(transitive)
+ Addedcolor-name@1.1.3(transitive)
+ Addedcolor-string@1.9.1(transitive)
+ Addedcolornames@1.1.1(transitive)
+ Addedcolorspace@1.1.4(transitive)
+ Addeddiagnostics@1.1.1(transitive)
+ Addedes6-weak-map@2.0.3(transitive)
+ Addedhtmlparser2@3.10.1(transitive)
+ Addedis-arrayish@0.3.2(transitive)
+ Addedis-promise@2.2.2(transitive)
+ Addedkuler@1.0.1(transitive)
+ Addedmemoizee@0.4.15(transitive)
+ Addedreadable-stream@3.6.2(transitive)
+ Addedsafe-buffer@5.2.1(transitive)
+ Addedsimple-swizzle@0.2.2(transitive)
+ Addedstring_decoder@1.3.0(transitive)
+ Addedtext-hex@1.0.0(transitive)
+ Addeduuid@3.4.0(transitive)
- Removednode-uuid@~1.4.7
- Removedasync@2.0.1(transitive)
- Removedcli-color@1.1.0(transitive)
- Removedcolor@0.8.0(transitive)
- Removedcolor-convert@0.5.3(transitive)
- Removedcolor-name@1.1.4(transitive)
- Removedcolor-string@0.3.0(transitive)
- Removedcolornames@0.0.2(transitive)
- Removedcolorspace@1.0.1(transitive)
- Removedcore-util-is@1.0.3(transitive)
- Removedd@0.1.1(transitive)
- Removeddiagnostics@1.0.1(transitive)
- Removedes6-iterator@0.1.3(transitive)
- Removedes6-symbol@2.0.1(transitive)
- Removedes6-weak-map@0.1.4(transitive)
- Removedhtmlparser2@3.9.2(transitive)
- Removedisarray@1.0.0(transitive)
- Removedkuler@0.0.0(transitive)
- Removedmemoizee@0.3.10(transitive)
- Removednext-tick@0.2.2(transitive)
- Removednode-uuid@1.4.8(transitive)
- Removedprocess-nextick-args@2.0.1(transitive)
- Removedreadable-stream@2.3.8(transitive)
- Removedsafe-buffer@5.1.2(transitive)
- Removedstring_decoder@1.1.1(transitive)
- Removedtext-hex@0.0.0(transitive)
Updatedargh@^0.1.4
Updatedasync@^2.1.5
Updatedcli-color@^1.2.0
Updateddiagnostics@^1.1.0
Updatedemits@^3.0.0
Updatedhtmlparser2@^3.9.2