Ruby and the Rails framework are both under active development and regular updates are released for both all year round.
Ruby, the creation of independent programmer, Yukihiro Matsumoto, began life over 20 years ago. In 2003, Chicago-based 37Signals launched the popular project management system, Basecamp. 37Signals had developed Basecamp in Ruby, and in 2005, they made the web application framework they’d developed — Rails — public.
Thanks to the versatility and ease of use of the framework, Ruby on Rails became the first choice for web application developers all over the world.
Airbnb, GitHub and the first version of Twitter were all written in Ruby. Frameworks such as Hanami and Sinatra emerged alongside Rails. In 2006 Ruby placed first in the Tiobe language ranking and maintained that position for another two years.
Ruby on Rails was one of the first frameworks to use the now well-known Model-View-Controller (MVC) pattern for dividing apps into logical components distinguished by role, rather than general area of functionality.
The framework promotes “agreement over configuration”, the result being that projects developed using MVC tend to have a similar basic structure and architecture, easing the transition of developers from project to project.
Databases
Rails introduced ActiveRecord, what’s known as an Object-Relational Mapping (ORM) system. Traditional web development involved manually embedding SQL statements into your code when you need to interact with a database such as PostgreSQL, Oracle, and MySQL.
Whilst this approach is simple in principle, it’s fraught with complexity in practice, with every query that needs to be parameterized being a potential candidate for attack by malicious parties.
ActiveRecord works differently: it represents your database as Ruby objects, and you interact with them just as you would any other Ruby object.
As you read and modify the objects in your code, ActiveRecord takes care of constructing and executing the correct — and safe — SQL queries for your chosen database behind the scenes.
No more escaping rules. No more conditional blocks to deal with different SQL implementations. Just plain Ruby code injected with a little magic.
The more complex an application, the harder it is to maintain. Fortunately, the Ruby ecosystem comes with a raft of standardized patterns and tools to ease the pain of verifying code quality, constructing and running automated test suites, and updating deployments.
Tools such as Minitest, Rspec, Capybara, and Cucumber helped to popularise approaches such as test-driven development (TDD) and behavior-driven development (BDD).
Ruby and the Rails framework are both under active development and regular updates are released for both all year round. Rails 6, released in the second half of 2019, introduced a number of new features:
Many of the changes and improvements are made in response to the Rails developer community. For example, there is a number of community-made tools to manage with user-provided files, but none offer the simplicity of being integrated into the framework.
According to Github, Rails has the largest number of active contributors out of all language frameworks on the platform.
So, if you choose Ruby and the Rails framework for your new project, you’ll benefit from a large and active community, tons of expert knowledge, and mature tools to help you get up and running quickly.
Previously published here.
(Disclaimer: The author of the story is the Chief Editor at Evrone)