support multiline tags

This commit is contained in:
wojtask9
2017-04-10 11:58:45 +02:00
parent 20044c4256
commit 3bc7caa387
4 changed files with 19 additions and 4 deletions
+1 -1
View File
@@ -9,7 +9,7 @@ function parse(html, filepath, options) {
html = whiteSpaceCtrl(html, options);
var tokens = [];
var syntax = /({%-?(.*?)-?%})|({{(.*?)}})/g;
var syntax = /({%-?([\s\S]*?)-?%})|({{([\s\S]*?)}})/g;
var result, htmlFragment, token;
var lastMatchEnd = 0, lastMatchBegin = -1, parsedLinesCount = 0;