Comparing version 0.2.2 to 0.2.3
@@ -129,3 +129,3 @@ "use strict"; | ||
var tmp = ""; // buffer for code output | ||
var codeBuffer = ""; // buffer for code output | ||
@@ -135,6 +135,6 @@ function appendCode() { | ||
state = "text"; | ||
if (!isWhitespace(tmp)) { | ||
content += codeOpen + tmp.replace(/^[\s\n]*/, "").replace(/[\s\n]*$/, "") + codeClose; | ||
if (!isWhitespace(codeBuffer)) { | ||
content += codeOpen + codeBuffer.replace(/^(?:\s*\n)+/, "").replace(/[\s\n]*$/, "") + codeClose; | ||
} | ||
tmp = ""; | ||
codeBuffer = ""; | ||
} | ||
@@ -173,6 +173,6 @@ } | ||
state = "code"; | ||
tmp = ""; | ||
codeBuffer = ""; | ||
} | ||
tmp += token.raw; | ||
codeBuffer += token.raw; | ||
} | ||
@@ -179,0 +179,0 @@ }); |
{ | ||
"name": "ljs", | ||
"description": "Generate docs from your source", | ||
"version": "0.2.2", | ||
"version": "0.2.3", | ||
"homepage": "https://github.com/phadej/ljs", | ||
@@ -6,0 +6,0 @@ "author": { |
@@ -31,2 +31,3 @@ # ljs | ||
- 0.2.3 Strip only empty lines from beginning of code blocks | ||
- 0.2.2 Whitespace handling for included files | ||
@@ -33,0 +34,0 @@ - 0.2.1 Dependencies update |
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
13059
72