diff2html
Advanced tools
Comparing version 3.4.22 to 3.4.23-34226g338cf5e.6.338cf5e
@@ -111,3 +111,4 @@ var __assign = (this && this.__assign) || function () { | ||
var _this = this; | ||
if (this.hljs === null) { | ||
var hljs = this.hljs; | ||
if (hljs === null) { | ||
throw new Error('Missing a `highlight.js` implementation. Please provide one when instantiating Diff2HtmlUI.'); | ||
@@ -117,4 +118,2 @@ } | ||
files.forEach(function (file) { | ||
if (_this.hljs === null) | ||
return; | ||
var language = file.getAttribute('data-lang'); | ||
@@ -132,4 +131,2 @@ if (!(_this.config.highlightLanguages instanceof Map)) { | ||
codeLines.forEach(function (line) { | ||
if (_this.hljs === null) | ||
return; | ||
var text = line.textContent; | ||
@@ -139,3 +136,3 @@ var lineParent = line.parentNode; | ||
return; | ||
var result = closeTags(_this.hljs.highlight(text, { | ||
var result = closeTags(hljs.highlight(text, { | ||
language: hljsLanguage, | ||
@@ -142,0 +139,0 @@ ignoreIllegals: true, |
@@ -114,3 +114,4 @@ "use strict"; | ||
var _this = this; | ||
if (this.hljs === null) { | ||
var hljs = this.hljs; | ||
if (hljs === null) { | ||
throw new Error('Missing a `highlight.js` implementation. Please provide one when instantiating Diff2HtmlUI.'); | ||
@@ -120,4 +121,2 @@ } | ||
files.forEach(function (file) { | ||
if (_this.hljs === null) | ||
return; | ||
var language = file.getAttribute('data-lang'); | ||
@@ -135,4 +134,2 @@ if (!(_this.config.highlightLanguages instanceof Map)) { | ||
codeLines.forEach(function (line) { | ||
if (_this.hljs === null) | ||
return; | ||
var text = line.textContent; | ||
@@ -142,3 +139,3 @@ var lineParent = line.parentNode; | ||
return; | ||
var result = (0, highlight_js_helpers_1.closeTags)(_this.hljs.highlight(text, { | ||
var result = (0, highlight_js_helpers_1.closeTags)(hljs.highlight(text, { | ||
language: hljsLanguage, | ||
@@ -145,0 +142,0 @@ ignoreIllegals: true, |
{ | ||
"name": "diff2html", | ||
"version": "3.4.22", | ||
"version": "3.4.23-34226g338cf5e.6.338cf5e", | ||
"homepage": "https://diff2html.xyz", | ||
@@ -5,0 +5,0 @@ "description": "Fast Diff to colorized HTML", |
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
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
No v1
QualityPackage is not semver >=1. This means it is not stable and does not support ^ ranges.
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
1916315
5335
1