Talks
Speakers
Events
Topics
Sign in
Home
Talks
Speakers
Events
Topics
Leaderboard
Use
Analytics
Sign in
Suggest modification to this talk
Title
Description
An unbelievable amount of features are packed into Rails making it one of the most powerful web frameworks you can use. @GorailsTV creator Chris Oliver takes a look at some little known, underused, and new things in Rails 7. A few of the topics covered: - ActiveRecord features like “excluding”, strict_loading, virtual columns, with_options, attr_readonly, etc - ActiveStorage named variants - ActionText embedding any database record - Custom Turbo Stream Actions with Hotwire - Turbo Native authentication with your Rails backend - ActiveSupport features like truncate_words - Rails 7.1’s new features: authentication, normalizes, logging background enqueue callers, and more. Links: https://rubyonrails.org/ https://rubyonrails.org/2023/10/5/Rails-7-1-0-has-been-released #RailsWorld #RubyonRails #Rails7 #opensource #OSS #Rails #ActiveRecord #ActiveStorage #ActiveSupport
Date
Summarized using AI?
If this talk's summary was generated by AI, please check this box. A "Summarized using AI" badge will be displayed in the summary tab to indicate that the summary was generated using AI.
Show "Summarized using AI" badge on summary page
Summary
Markdown supported
In the video titled "Powerful Rails Features You Might Not Know" presented by Chris Oliver at Rails World 2023, the speaker delves into a variety of powerful yet often overlooked features of the Rails framework, particularly focusing on updates and enhancements introduced in Rails 7 and 7.1. With a runtime of approximately 35 minutes, Oliver emphasizes the importance of familiarizing oneself with the latest capabilities of Rails to improve development efficiency and solve problems more effectively. ### Key Points Discussed: - **ActiveRecord Enhancements:** - Introduced an 'excluding' method to simplify querying users by excluding those who opted out of notifications. - Added 'strict_loading' which helps avoid N+1 query problems by enforcing the loading of associated records. - Features like 'attr_readonly' that protect specific attributes from being changed and 'with_options' that reduce redundancy in method calls. - **ActiveStorage and ActionText Features:** - Named variants in ActiveStorage for better image management. - ActionText allows embedding Active Record models in rich text, enhancing dynamic interactions in applications. - **Innovations in Turbo and Hotwire:** - Discussed custom Turbo Stream actions that enhance real-time user interactions and notifications during long-running processes. - **ActiveSupport Utilities:** - Features like 'truncate_words' for better text handling and various time helper methods that enhance productivity in time-related queries. - **Updates in Rails 7.1:** - New features such as 'local environment checking', 'unused resources routes', 'template strict locals', and improved authentication capabilities with has_secure_password. - Enhanced Active Storage for easier image variant management and streamlined processes for generating secure authentication tokens. ### Significant Examples: Oliver illustrates the usage of the 'excluding' method through a real-world scenario where notifications to users need to be sent while excluding certain individuals. This shows how the method abstracts SQL complexities, allowing developers to focus on requirements rather than low-level database queries. Additionally, he discusses the ability to embed Active Record models in rich text through ActionText, enhancing the way users interact with text content in modern Rails applications. ### Conclusion and Takeaways: Oliver concludes by encouraging developers to continuously learn and stay updated with the latest features in Rails, as this knowledge can significantly boost productivity and make coding experiences smoother. He emphasizes that understanding and utilizing these features can contribute substantially to building more efficient and maintainable web applications.
Suggest modifications
Cancel