Asset Management in Rails: From Sprockets to Propshaft
Asset management in Rails has evolved significantly. This article examines the shift from Sprockets to Propshaft, the role of js-bundling and css-bundling, and when to choose each approach.
Asset management in Rails has evolved significantly. This article examines the shift from Sprockets to Propshaft, the role of js-bundling and css-bundling, and when to choose each approach.
In the latest Rails, a significant change has been made to the behaviour of transactions. Specifically, using return, break, or throw statements will no longer trigger an automatic rollback of the transaction. In Rails 6.1 use of return, break, and t...
Rails provides has_secure_password class method to store passwords securely. You need to have password_digest attribute in your model to get it working. For example, if you have a user model class User < ApplicationRecord has_secure_password end T...
{% codeblock lang:ruby%} class User include TestModule
Rails3 define routes in more efficient way Routes for CRUD actions
In Rails3 Active Model feature is added that helps to use feature of active record class for a non active record class.In Active Model you can make Any Ruby Object Feel Like Active Record and can g...