What are the differences betweeen Rails 2.x and Rails 3

Answer Posted / dayanthan

(1) Introduction of bundler (New way to manage your gem
dependencies)
* (2) Gemfile and Gemfile.lock (Where all your gem
dependencies lies, instead of environment.rb)
* (3) A new .rb file in config/ folder, named as
application.rb (Which has everything that previously
environment.rb had)
* (4) Change in SQL Structure: Model.where(:activated => true)
* (5) All the mailer script will now be in app/mailers
folder, earlier we kept inside app/models.
* (6) Rails3-UJS support. for links and forms to work as
AJAX, instead of writing complex lines of code, we write
:remote => true
* (7) HTML 5 support.
* (8) Changes in the model based validation syntax:
validates :name, :presence => true
* (9) Ability to install
windows/ruby/jruby/development/production specific gems to
Gemfile.
group :production do
gem 'will_paginate'
end

Is This Answer Correct ?    22 Yes 2 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is a proc ?

553


Explain view in rails?

491


Are there any disadvantages of ruby on rails? If yes, mention them.

483


What is the difference between Render vs. Redirect_to in ruby on rails ?

504


Can you list out what can rails migration do?

462






What do you understand by rails migration and what it can do?

446


Explain what is the role of the subdirectories app/controllers and app/helpers in rails?

500


Write the command to update rvm in rails.

476


What is agile development? What are the strengths?

480


How you run your rails application without creating databases?

458


how can you declare a block in Ruby?

502


What is the difference between delete and destroy ?

478


Explain what are the servers supported by ruby on rails?

450


how many types of callbacks available in ror?

599


What is the latest version of ruby on rails?

512