Top "Spacebars" questions

Spacebars is a Meteor template language inspired by Handlebars.

How can I get the index of an array in a Meteor template each loop?

Say I have an object, someObject: { foo: "apple", myArray: ["abc", "def"] } And a template helper that looks like this (and …

javascript meteor spacebars
Meteor: Access Template Helper (or variable) from another helper

How can I reference a template helper from another one? For example... Template.XXX.helpers({ reusableHelper: function() { return this.field1 * 25 / 100; //…

meteor meteor-blaze spacebars meteor-helper
How can I use if condition on the meteor template?

I want to use an if condition in a Meteor Blaze template. Let's say you have a helper users on …

javascript meteor spacebars
Change column name in MariaDB

I have this column in this database with a spacebar included, which I want to change. ALTER TABLE . CHANGE COLUMN `…

mariadb spacebars
Check for equality in Spacebars?

I am trying to do what I think should be a very simple task, but have been failing to do …

if-statement meteor equals conditional-statements spacebars
How Do I Access an Object's Properties From a Template?

According to http://handlebarsjs.com/expressions.html, I should be able to do this: <h1>{{article.title}}</…

javascript meteor spacebars
How to pass multiple arguments to Spacebars helper from Meteor template?

I haven't been able to find a solid example out there. Template.registerHelper("itemLookup", function(sku, property){ return Items.findOne({…

meteor spacebars
spacebars: how to use and / or in if statements

I have following code: <div class="form-group {{#if afFieldIsInvalid name='latitude' OR name='longitude'}}has-error{{/if}}">......</div&…

meteor spacebars