0
我一直在搜索sammy.js和車把的文檔很長一段時間,我不能爲我的生活,確定在http://sammyjs.org/docs/api/0.7.1/all#Sammy.Handlebars(示例#2)mypartial.hb被指示加載到{{> hello_friend}}。想法?把手部分在Sammy.js
我一直在搜索sammy.js和車把的文檔很長一段時間,我不能爲我的生活,確定在http://sammyjs.org/docs/api/0.7.1/all#Sammy.Handlebars(示例#2)mypartial.hb被指示加載到{{> hello_friend}}。想法?把手部分在Sammy.js
我這個問題是舊的,但對所有sammyjs情人
var app = $.sammy('#app', function(){
this.use('Mustache', 'ms');
this.get('#/hello/:name/to/:friend', function(context){
this.load('mypartial.ms')
.then(function(partial){
context.partials = {hello_friend: partial};
context.name = context.params.name;
context.friend = context.params.friend;
context.partial('mytemplate.ms');
});
});
});
http://sammyjs.org/docs/api/0.7.4/all#Sammy.Handlebars 注意的版本是0.7.4
哪裏/如何實現這部分的.hb文件中提出? – user1260745 2012-08-17 02:21:24
是的,當然。這怎麼可能在Sammy中實現 – user1260745 2012-08-17 02:26:52