htmljs-parser
Advanced tools
Comparing version 2.2.7 to 2.3.0
@@ -248,2 +248,5 @@ exports.createNotifiers = function(parser, listeners) { | ||
type: 'scriptlet', | ||
tag: scriptlet.tag, | ||
line: scriptlet.line, | ||
block: scriptlet.block, | ||
value: scriptlet.value, | ||
@@ -250,0 +253,0 @@ pos: scriptlet.pos, |
@@ -41,3 +41,3 @@ { | ||
}, | ||
"version": "2.2.7" | ||
"version": "2.3.0" | ||
} |
@@ -64,2 +64,6 @@ var fs = require('fs'); | ||
if (name.indexOf('.skip') === name.length-5) { | ||
itFunc = it.skip; | ||
} | ||
var dir = path.join(autoTestDir, name); | ||
@@ -66,0 +70,0 @@ |
@@ -85,3 +85,9 @@ 'use strict'; | ||
case 'scriptlet': { | ||
out.writeLine('scriptlet:' + JSON.stringify(event.value)); | ||
if(event.tag) { | ||
out.writeLine('scriptlet:' + JSON.stringify(event.value)); | ||
} else if (event.line) { | ||
out.writeLine('scriptlet(line):' + JSON.stringify(event.value)); | ||
} else if (event.block) { | ||
out.writeLine('scriptlet(block):' + JSON.stringify(event.value)); | ||
} | ||
break; | ||
@@ -335,4 +341,6 @@ } | ||
onScriptlet: (event) => { | ||
expect(src.substring(event.pos, event.pos+2)).to.equal('<%'); | ||
expect(src.substring(event.endPos-2, event.endPos)).to.equal('%>'); | ||
if (event.tag) { | ||
expect(src.substring(event.pos, event.pos+2)).to.equal('<%'); | ||
expect(src.substring(event.endPos-2, event.endPos)).to.equal('%>'); | ||
} | ||
this.last.children.push(new Node(event)); | ||
@@ -339,0 +347,0 @@ }, |
Sorry, the diff of this file is too big to display
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
New author
Supply chain riskA new npm collaborator published a version of the package for the first time. New collaborators are usually benign additions to a project, but do indicate a change to the security surface area of a 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
246459
954
3741
1