Thursday, September 17, 2009

Five Fundamentals of Ruby on Rails

Today’s applications developer aiming for the next scintillating Web 2.0 site is spoiled for choice. How well, you might wonder, does Ruby on Rails live up to its promise to simplify development tasks while crafting rich visitor experiences?

Part of the answer, I am assured by the intense and prolific young developers of HyTech Professionals (www.hytechpro.com) is to keep in mind some fundamentals of Ruby on Rails. These comprise:

1. That it is really is possible to produce the same functionality with distinctly fewer lines of code. This is due in large part to the fact that Matsumoto created Ruby back in 1995 as an object-oriented, dynamically defined, and easy-reading language. One does have to be creative with blocks that blend loops and arrays, however.

2. RoR architecture promotes clarity by, for one, segregating code across three sub-frameworks: Active Record, Action View, and Action Controller.

3. Declare it once and that’s it. The Ruby on Rails environment leans mightily toward re-use of all kinds of system knowledge, whether this be data/metadata, algorithm, functionality or logic. This principle of hardly ever repeating yourself is paramount in Active Record where the database, not program code, defines attributes and class values.

4. Ruby on Rails relies on convention and binds components to work together with just one configuration file, “database.yml”. Even this simply defines data or objects and keeps the user names and passwords for the application database.

5. Finally, RoR is remarkable for speeding up work with the “scaffold” console command, generators that equate to modules for repetitive elements (a log-in form, for instance), and blink-of-an-eye progress checks simply by reloading the application in a browser.

All the above reinforce the superior productivity that is possible with Ruby on Rails. But if these do not yet persuade you to at least learn more about RoR, perhaps a closer look at framework components in my next post just might.

1 comment:

Ranvir Singh said...

loved reading your blog....
Thanks for sharing the information....
Thanks