Comparing version 1.2.0 to 1.2.1
11
index.js
@@ -15,2 +15,3 @@ var through = require('through'); | ||
var skipping = false; | ||
var lastToken = null; | ||
@@ -64,2 +65,9 @@ tokens.pipe(through(write, end)); | ||
r.on('_write-begin', function (stream) { | ||
if (lastToken[0] === 'tag-end' | ||
&& lastToken[1].length > 0 | ||
&& '>' === String.fromCharCode(lastToken[1][lastToken[1].length-1]) | ||
) { | ||
tr.queue(lastToken[1]); | ||
} | ||
if (stream._skipping !== false) { | ||
@@ -101,2 +109,4 @@ tokens.pause(); | ||
function write (lex) { | ||
lastToken = lex; | ||
var sub; | ||
@@ -112,3 +122,2 @@ selectors.forEach(function (s) { | ||
if (skipping) return; | ||
if (sub !== undefined) tr.queue(sub) | ||
@@ -115,0 +124,0 @@ else tr.queue(lex[1]) |
{ | ||
"name" : "trumpet", | ||
"version" : "1.2.0", | ||
"version" : "1.2.1", | ||
"description" : "parse and transform streaming html using css selectors", | ||
@@ -5,0 +5,0 @@ "main" : "index.js", |
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
41078
45
1012
18