-
Notifications
You must be signed in to change notification settings - Fork 159
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
HandlebarsTemplates object not defined without backing model #164
Comments
@jwlms what do you mean by a backing model? (unfamiliar with the use of that term) |
Have you potentially set the |
I just mean a model in general. A
I did attempt this at an earlier point just to see if I could get this gem working, but was unsuccessful. Currently I don't have |
I'm seeing the same behavior with a new rails app. There doesn't seem to be anything created in the |
@AlexRiedler - I put up a PR to fix the issue I've run into. This seems like it should have limited side effects, but I don't know the project well. Alternatively, to get this to work on Rails 3 I was able to add this to my
Which could be used as an alternative to the PR if it's not up to spec. |
cleaning up, going to close cause referenced PR was merged, and making sure this all works with Rails 7 |
I've been trying (and failing) to integrate this gem into non-standard Rails 3 application (which is mostly JavaScript and lacks a typical backing model).
The example provided in the README is a Contact model:
My primary question is:
Does this gem work without a backing model? As following the steps in the README for my use case, provides me with a consistent error message of
HandlebarsTemplates is not defined
. I have templates in the templates directory and am able to manually precompile the templates and include them into the application with the runtime and access them underHandlebars.templates.generic_handlebars_template
.Is there a step I'm missing for this use case:
Any help here would be greatly appreciated!
The text was updated successfully, but these errors were encountered: