summaryrefslogtreecommitdiffstats
path: root/lib/handlebars/compiler/compiler.js
diff options
context:
space:
mode:
authorLes Hill <leshill@gmail.com>2012-12-13 10:33:20 -0800
committerLes Hill <leshill@gmail.com>2012-12-13 11:15:38 -0800
commit4bb794d814d068361a101a87735e2b9bbcee5115 (patch)
tree954c5fab968696bc3364671ecca47e6ac6c8a4f9 /lib/handlebars/compiler/compiler.js
parentfd0560b95124bd6d335c0bd6af907281a22d72ea (diff)
downloadhandlebars.js-4bb794d814d068361a101a87735e2b9bbcee5115.zip
handlebars.js-4bb794d814d068361a101a87735e2b9bbcee5115.tar.gz
handlebars.js-4bb794d814d068361a101a87735e2b9bbcee5115.tar.bz2
Partials can be paths
Allows partials with slashes, a common partial syntax. For example: {{> shared/dude}}
Diffstat (limited to 'lib/handlebars/compiler/compiler.js')
-rw-r--r--lib/handlebars/compiler/compiler.js4
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/handlebars/compiler/compiler.js b/lib/handlebars/compiler/compiler.js
index 7578dd2..31f9f4b 100644
--- a/lib/handlebars/compiler/compiler.js
+++ b/lib/handlebars/compiler/compiler.js
@@ -160,7 +160,7 @@ Handlebars.JavaScriptCompiler = function() {};
},
partial: function(partial) {
- var id = partial.id;
+ var partialName = partial.partialName;
this.usePartial = true;
if(partial.context) {
@@ -169,7 +169,7 @@ Handlebars.JavaScriptCompiler = function() {};
this.opcode('push', 'depth0');
}
- this.opcode('invokePartial', id.original);
+ this.opcode('invokePartial', partialName.name);
this.opcode('append');
},