Be sure to match the versions of the Handlebars server and client packages. A way to check the version of the compiled template is the following:
handlebars a_template_of_yours.handlebars | grep "compilerInfo"
It should output something like this:
this.compilerInfo = [4,'>= 1.0.0'];
The first value is the Compiler Revision, which should match the output of the following code on your browser:
Handlebars.COMPILER_REVISION
If you used npm to download your Handlebars compiler, specify the version which you need. Here is an example for handlebars.runtime-v1.3.0.js:
npm install handlebars@1.3.0 -g
与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…