summaryrefslogtreecommitdiffstats
path: root/lib/handlebars/compiler/compiler.js
diff options
context:
space:
mode:
authorKevin Decker <kpdecker@gmail.com>2014-08-13 09:16:08 -0500
committerKevin Decker <kpdecker@gmail.com>2014-08-13 09:16:08 -0500
commit867322adf28a2babfa22c46558d388091b5756e8 (patch)
tree0acee3600b07bc15edc6e6531b756dcc32bfe96d /lib/handlebars/compiler/compiler.js
parent3288f525f3600c7501f521ad0e97b3126c5ed201 (diff)
parentf2a2914d4fb38095105c963086425ba75121ae7b (diff)
downloadhandlebars.js-867322adf28a2babfa22c46558d388091b5756e8.zip
handlebars.js-867322adf28a2babfa22c46558d388091b5756e8.tar.gz
handlebars.js-867322adf28a2babfa22c46558d388091b5756e8.tar.bz2
Merge pull request #787 from wycats/standalone-mustaches
Remove whitespace surrounding standalone statements
Diffstat (limited to 'lib/handlebars/compiler/compiler.js')
-rw-r--r--lib/handlebars/compiler/compiler.js6
1 files changed, 4 insertions, 2 deletions
diff --git a/lib/handlebars/compiler/compiler.js b/lib/handlebars/compiler/compiler.js
index 3e83a62..131cb98 100644
--- a/lib/handlebars/compiler/compiler.js
+++ b/lib/handlebars/compiler/compiler.js
@@ -217,12 +217,14 @@ Compiler.prototype = {
this.opcode('push', 'depth0');
}
- this.opcode('invokePartial', partialName.name);
+ this.opcode('invokePartial', partialName.name, partial.indent || '');
this.opcode('append');
},
content: function(content) {
- this.opcode('appendContent', content.string);
+ if (!content.omit) {
+ this.opcode('appendContent', content.string);
+ }
},
mustache: function(mustache) {