lit-nunjucks
Advanced tools
Comparing version
@@ -133,3 +133,3 @@ const nunjucks = require("nunjucks"); | ||
!variblesInScope.includes(firstPart) && | ||
!["html", "repeat"].includes(firstPart) | ||
!["html", "repeat", "_F"].includes(firstPart) | ||
) { | ||
@@ -157,2 +157,3 @@ variblesInScope.push(firstPart); | ||
), | ||
t.identifier("_F"), | ||
], | ||
@@ -168,2 +169,3 @@ t.blockStatement([ | ||
), | ||
] | ||
@@ -357,3 +359,11 @@ : []), | ||
array, | ||
t.arrowFunctionExpression( | ||
[t.identifier("t")], | ||
t.callExpression(t.identifier("JSON.stringify"), [ | ||
t.identifier("t"), | ||
]) | ||
), | ||
t.arrowFunctionExpression( | ||
[ | ||
@@ -382,3 +392,3 @@ node.name instanceof n.Array | ||
]); | ||
return t.conditionalExpression( | ||
@@ -397,3 +407,3 @@ node.else_ | ||
repeatCallExpression, | ||
node.else_ ? this.wrapTemplate(node.else_) : t.stringLiteral('') | ||
node.else_ ? this.wrapTemplate(node.else_) : t.stringLiteral("") | ||
); | ||
@@ -400,0 +410,0 @@ } |
{ | ||
"name": "lit-nunjucks", | ||
"version": "1.0.2", | ||
"version": "1.0.3", | ||
"description": "Nunjucks compiler to lit-html", | ||
@@ -5,0 +5,0 @@ "main": "lit-nunjucks.js", |
51415
0.63%1261
0.56%