htmljs-parser
Advanced tools
Comparing version 1.5.13 to 1.6.0
@@ -5,3 +5,3 @@ exports.createNotifiers = function(parser, listeners) { | ||
return { | ||
notifyText(value) { | ||
notifyText(value, textParseMode) { | ||
if (hasError) { | ||
@@ -16,3 +16,4 @@ return; | ||
type: 'text', | ||
value: value | ||
value: value, | ||
parseMode: textParseMode | ||
}, parser); | ||
@@ -19,0 +20,0 @@ } |
@@ -38,3 +38,3 @@ { | ||
}, | ||
"version": "1.5.13" | ||
"version": "1.6.0" | ||
} |
@@ -9,3 +9,2 @@ var chai = require('chai'); | ||
var TreeBuilder = require('./TreeBuilder'); | ||
var expect = require('chai').expect; | ||
@@ -12,0 +11,0 @@ require('colors'); |
@@ -48,3 +48,7 @@ 'use strict'; | ||
case 'text': { | ||
out.writeLine('text:' + JSON.stringify(event.value)); | ||
var line = 'text:' + JSON.stringify(event.value); | ||
if (out.includeTextParserState) { | ||
line += ' [parseMode=' + event.parseMode + ']'; | ||
} | ||
out.writeLine(line); | ||
break; | ||
@@ -163,2 +167,4 @@ } | ||
this.includeLiteralValues = options && options.includeLiteralValues === true; | ||
this.includeTextParserState = options.includeTextParserState === true; | ||
this.root = new RootNode(); | ||
@@ -330,2 +336,3 @@ this.stack = [this.root]; | ||
includeLiteralValues: this.includeLiteralValues === true, | ||
includeTextParserState: this.includeTextParserState === true, | ||
incIndent() { | ||
@@ -332,0 +339,0 @@ indent += ' '; |
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
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
176919
428
3083