Keeping Up with the Bleeding Edge
I’ve just gobbled up some concepts, innovations, and basically best practices regarding rails and ajax. To summarize these are:
- Markaby (ruby html templates)
- RJS Templates (javascript generation)
- Centralized activity indicators
- Graceful degradation
Markaby
http://redhanded.hobix.com/inspect/markabyForRails.html
To install, just type in :
script/plugin install http://code.whytheluckystiff.net/svn/markaby/trunk
Cool follow-up read here :
http://ruby.cycnus.de/articles/06/jan/markaby/
RJS
http://www.codyfauser.com/articles/2005/12/05/rjs-templates-plugin-subversion-repository
Type in
script/plugin install http://www.codyfauser.com/svn/projects/plugins/javascript_generator_templates/
Good tutorials here :
Centralized Activity Indicators
http://mir.aculo.us/articles/2005/11/14/ajax-activity-indicators-with-rails-0-14-3
Basically, you’ll just have to create JS file with roughly 6 lines of code, and choose a nice location where you want your activity indicator to appear. When a new AJAX Request is started, it will appear (or show via one of the effects) and disappear. Talk about being DRY.