javascript - Can I declare local/temp variables within a jQuery template? -
is possible declare new variables within jquery template syntax? i'm hoping achieve equivalent of (which not work):
{{var test = "test"}} <div> ${test} </div>
this pretty lame, 1 trick might work is:
{{each(i, test) ["test"]}} blah blah ${test} blah {{/each}}
i'm not 100% sure using array constant expression that; i'll set fiddle. (edit yes works :-)
Comments
Post a Comment