forked from AlchemyCMS/alchemy_cms
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
2 changed files
with
4,609 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
22affc1
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can you use the https://github.com/leshill/handlebars_assets gem insteas of committing the entire JS library to the Alchemy repo? That way, we can offload updates of that library to the gem instead of having to maintain ourselves.
22affc1
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, absolutely! Also, the templates will be precompiled with
rake assets:precompile
and we can get rid ofscript
tags and use.hbs
templates instead.22affc1
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Good idea! I'll see what I can do. The
_page.html.erb
template does use some controller variables (mostly for sorting). So that might be a little more complex than that. Having the Handlebars asset in a gem is a good idea regardless.22affc1
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why not add the
@sorting
also to the json response? It's more like a "show children and all buttons on the right" toggle, then anything else.22affc1
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
True. That's a good point.
I'm running into the leshill/handlebars_assets#141 problem too. I'm going to leave this unsolved for now while I'm fixing more important things.