Skip to content

Handlebars.precompile throws version error yet uses same script #806

Closed
@code-for-coffee

Description

@code-for-coffee

Hi,

This issue pertains to Handlebars 2.0.0alpha4 (I have resolved the same issue w/1.3.0).

I've been using Handlebars.precompile() to precompile Handlebars templates in an environment that cannot have Node.js installed. I am using the latest version of Handlebars.js and am using the .precompile function, assigning a template, and passing an object in for rendering. I am thrown the error: "Error: Template was precompiled with an older version of Handlebars than the current runtime. Please update your precompiler to a newer version (>= 2.0.0) or downgrade your runtime to an older version (<= 1.0.rc.2)."

I am a little stumped here because I'm using the exact same library file (handlebars.js) to both execute the precompile as well as render the file (originally I was just using the runtime). I'm receiving the same error either way.

I've included a Fiddle that displays the exact issue that I am running into. It is as follows:

http://jsfiddle.net/BqZWL/4/

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions