node-blade

Using Bladejs with Meteor

时光总嘲笑我的痴心妄想 提交于 2019-12-10 10:14:52
问题 I recently added the node-blade smart package to my meteor and have static content displaying fine. However, I'm not able to use any template variables. Before I installed blade, the template variables worked fine with handlebars. Does anybody know what I'm doing wrong? console output ReferenceError: player is not defined at ~/meteor/project/views/info.blade:1:1 1 > .player-name.large= player.name 2 | .alliance-name= alliance.name 3 | .world-name= world.name 4 | at eval (eval at <anonymous> (

metor blade template throws “second landmark in same branch” exception in for loop

让人想犯罪 __ 提交于 2019-12-07 06:09:08
问题 I have a for loop that I want to include a template view in: table.blade: #game h1= table.name -if( table.playerSitting() ) a.btn.btn-danger.stand(href="#") Stand #table -for (var i=0; i<7;i++) include 'seat' exposing i seat.blade: - id = 'p' + (i+1) div(id="#{id}") -if (table.hasAt(i)) p= table.usernameAt(i) -else -if( !table.playerSitting() ) a.btn.btn-inverse.sit(href="#", data-key="#{i}") Sit -else p   When I first load the view, everything draws fine. But if I sit or stand, or go to

Using Bladejs with Meteor

蹲街弑〆低调 提交于 2019-12-05 21:18:09
I recently added the node-blade smart package to my meteor and have static content displaying fine. However, I'm not able to use any template variables. Before I installed blade, the template variables worked fine with handlebars. Does anybody know what I'm doing wrong? console output ReferenceError: player is not defined at ~/meteor/project/views/info.blade:1:1 1 > .player-name.large= player.name 2 | .alliance-name= alliance.name 3 | .world-name= world.name 4 | at eval (eval at <anonymous> (/usr/local/lib/node_modules/blade/lib/compiler.js:138:23)) at /usr/local/lib/node_modules/blade/lib

metor blade template throws “second landmark in same branch” exception in for loop

天大地大妈咪最大 提交于 2019-12-05 10:39:18
I have a for loop that I want to include a template view in: table.blade: #game h1= table.name -if( table.playerSitting() ) a.btn.btn-danger.stand(href="#") Stand #table -for (var i=0; i<7;i++) include 'seat' exposing i seat.blade: - id = 'p' + (i+1) div(id="#{id}") -if (table.hasAt(i)) p= table.usernameAt(i) -else -if( !table.playerSitting() ) a.btn.btn-inverse.sit(href="#", data-key="#{i}") Sit -else p   When I first load the view, everything draws fine. But if I sit or stand, or go to another table, I get this: Exception from Deps recompute: Error: Can't create second landmark in same