Hello all Rubyists, This is my first blog post on dev.to and I'm very excited to start off. Here we go, As per ruby on rails guide, Active Support is the Ruby on Rails component responsible for providing Ruby language extensions and utilities.
Active Support in Ruby on Rails enhances the capabilities of the Ruby language by adding more features and utilities, making it easier for developers to build web applications efficiently.
What does that really mean?
It means that you can do a lot of really cool stuffs with Active Support that you cannot do in regular Ruby code. For example, When I use 'person'.pluralize in an irb and see what happens below
We are getting NoMethodError in Ruby β thatβs where ActiveSupport can come in. Active Support automatically provides methods, such as .pluralize, .singularize and many more methods to Rails applications. The same method in a rails console.
Now it works! It is just an intro to Active Support. There many more methods available. Please checkout the official docs to know more. active support guide Thanks for reading!
Top comments (2)
Hi ! Welcome on Dev.to :)
What are the top 6 methods you like the most on ActiveSupport ?
Hi @V These are my favorite methods: