16 RJS Resources and Tutorials for Rails Programmers
Please note that this post is over four years old - it's from 2006! As such, these tips were relevant to Rails 1.2 and this content is woefully out of date. We will be updating it for Rails 3 soon! For now, head to the Ruby Inside homepage to find something else to read or check out the Ruby on Rails 3 Tutorial book and screencast which will bring you up to speed with all things Rails 3.
Introduction / Tutorials
- Simple RJS Tutorial - An up to date RJS tutorial (May 2006) featuring a video demonstration and some code.
- RJS Tutorial by FearOfFish - Another overall tutorial with a demonstration view, controller, and RJS template for adding a shopping cart type system to a page.
- Real-world Rails RJS Templates - An introductory look at the benefits of RJS templates posted close to their introduction in December, 2005.
- Ajaxed forms with RJS templates - Technoweenie demonstrates how an entire form can be processed and manipulated using AJAX and RJS. Lots of nice syntax colored code!
- A Demo of RJS - A live demo of what RJS can do, including code.
- Redirection with RJS and AJAX - Showing some code to make a login process easier with RJS.
- Official RJS documentation from the Rails API docs - The official docs don't usually show the latest tricks, but it's great for the basics.
- RJS Template Methods - A list of methods supported by RJS templates from February 2006 (before Rails 1.1). It includes some demonstration code to put together a small app using RJS.
- RJS Templates, simplified - Another basic list of the RJS methods.
Miscellaneous / Advanced
- Add RJS support to TextMate - TextMate doesn't understand RJS by default, and this post shows you how to get the syntax coloring working.
Debugging and Testing
- AjaxSpy - A cute way to debug and monitor RJS requests directly from the page. Only works in FireFox and Safari.
- Tips for debugging RJS code - A list of useful tips and considerations when debugging RJS code.
- RJS Assertions Plugin - A plugin to help you with testing your RJS.
- RJS Assertions and Testing - Useful tips for testing RJS code and responses.