HandlebarsHelper will help you bundle your templates in an ASP.Net application
Questions tagged [handlebarshelper]
165 questions
12
votes
2 answers
Handlebars: Get index of an item when there are two rows of items
The @key below always gives 0 1 2 3 even in the second row. Please help.
Handlebars template:
{{#grouped_each 4 orderData}}
{{#each this }}

vini
- 4,657
- 24
- 82
- 170
8
votes
0 answers
Is there a way to pass variables into PugJS filters
Using Pug filters and the jsTransformer-handlebars module I'm trying to insert some handlebars code into a pug template that will make use of locals. However, since Pug renders filters at compile time, we can't make use of the templates locals. So…

Edward Soto
- 101
- 5
8
votes
1 answer
Handlebars If-Else If-Else With String Equality Function
HandlebarsJS doesn't support string equality ('==') so I have to write my own helper, but this answer isn't clear:
https://stackoverflow.com/a/15095019/1005607
Handlebars.registerHelper('if_eq', function(a, b, opts) {
if(a == b) // Or ===…

gene b.
- 10,512
- 21
- 115
- 227
6
votes
1 answer
What's the syntax for creating HandleBars helpers server side?
Using Handlebars.Net, I'd like to create a HandlebarsHelper that will replace carriage returns and newlines with
tags. It should look something like this: string pattern = @"/(\r\n|\n|\r)/gm"; string replacement = "
"; Regex rgx = new…
tags. It should look something like this: string pattern = @"/(\r\n|\n|\r)/gm"; string replacement = "
"; Regex rgx = new…

BobbyA
- 2,090
- 23
- 41
6
votes
4 answers
How to write Helpers in HTMLBars?
After the latest release of EmberJS v1.9.0 I am trying to move from Handlebars to HTMLbars. What I am finding very challenging is lack of documentation.
I am trying to implement very simple helpers.
For example take this handlebars…

Sisir
- 2,668
- 6
- 47
- 82
5
votes
3 answers
How to use helpers in handlebars with webpack(handlebars-loader)
I am using Handlebars in my project and bundling templates using webpack. I am using handlebars-loader to compile templates. I got issue when I created a small helper. Webpack shows this error when I use helper in my template:
You specified…

Bharat Soni
- 2,824
- 6
- 23
- 48
5
votes
0 answers
How to make handlebars-loader used in conjunction with handlebars-helpers
how the handlebars-loader to work with handlebars-helpers?
webpack.configs:
{ // handlebars-loader
test: /\.handlebars$/,
loader: "handlebars-loader?helperDirs[]=" + __dirname + "/helpers"
}
but, how to import handlebars-helpers and…

robin
- 61
- 3
5
votes
5 answers
TypeError: Handlebars.registerHelper is not a function
I am brand new to node and handlebars as of two days ago so bear with me.
I am trying to use custom handlebars helpers but am not entirely sure where to put it.
I keep getting "TypeError: Handlebars.registerHelper is not a function"
Right now I have…

Sho Nuff
- 51
- 1
- 1
- 3
4
votes
1 answer
Remove Spaces inside tripe brackets Handlebars | HTML Language Features in Script Tag | Vs code
I'm having issues with Handlebar triple brackets formatting when inside a script tag. Attaching a gif for this issue as it's hard to explain in words.
Any help would be appreciated.