Closed Esthetech closed 8 years ago
Hey there @Hoenoe! A better place to ask questions might be our gitter chatroom, this is more a place for things that might be an error with roots.
In this case, your issue is entirely outside the scope of roots. Roots' use of handlebars is to compile templates into static html files, which is is doing exactly as intended. You are trying to use handlebars through javascript on the client side, so you should not be using handlebars through roots, as the two might conflict, and this is probably the source of your issue.
Try changing the file extension to .html
and running it that way.
Hey @jescalan,
Thank you for your help!
This clarified things and changing the extension to .html
did the trick.
Great! If you want to precompile the templates, you could always try the client-templates extension as well
Would love some help here..
I removed Jade and installed handlebars.js with:
$ npm i handlebars -S
Renamed the extentions to index.hbs.
And for a little test I put in the code below: But nothing gets compiled.
package.json file:
When I add in the handlebars.js through a cdn it removes the text 'This will get replaced by handlebars.js'. But does also not compile it correctly and is outputs this in the console:
What am I doing wrong?
And as side question. Is it oke to ask this questions onder the issues section of projects or is there a other place for asking help with this kind of questions? Still a bit new to github and coding in general :)