惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

博客园 - 叶小钗
WordPress大学
WordPress大学
Hugging Face - Blog
Hugging Face - Blog
T
Tailwind CSS Blog
博客园 - 三生石上(FineUI控件)
量子位
月光博客
月光博客
人人都是产品经理
人人都是产品经理
U
Unit 42
S
SegmentFault 最新的问题
M
MIT News - Artificial intelligence
H
Help Net Security
aimingoo的专栏
aimingoo的专栏
Microsoft Security Blog
Microsoft Security Blog
MyScale Blog
MyScale Blog
美团技术团队
P
Proofpoint News Feed
Apple Machine Learning Research
Apple Machine Learning Research
D
Docker
B
Blog
大猫的无限游戏
大猫的无限游戏
V
Visual Studio Blog
钛媒体:引领未来商业与生活新知
钛媒体:引领未来商业与生活新知
G
Google Developers Blog

Ruby on Rails: Compress the complexity of modern web apps

Safer to_i coercion, custom to_fs formats, and more! This Week in Rails: May 16, 2026 This Week in Rails: May 8, 2026 This Week in Rails: May 1, 2026 Active Record gets better every week Great big Rails World 2026 update: CFP, Corporate Support tickets, workshops Query command for database queries and more Explicit query: and body: kwargs for integration tests and more! Speedup ActiveRecord::LogSubscriber#sql_color and more! This Week in Rails: March 27, 2026 Rails Versions 8.0.5 and 8.1.3 have been released! Rails Versions 7.2.3.1, 8.0.4.1, and 8.1.2.1 have been released! This Week in Rails: March 20, 2026 Validate URI scheme in Action Text and more This Week in Rails: March 6, 2026 Planning Center is the newest Rails Foundation Contributing member Action Text gets Markdown conversion, editor links in devcontainers, and more! BARRA seeks Rails developer Joe Agliozzo is looking for a Rails developer The rise of lighttpd as the alternative web server When longer is better and more is more Snowdevil: First e-tailer on Rails Natural selection for frameworks in Ruby vs Java Address book tutorial in Portuguese Becoming a better programmer with Rails 10 Things Every Java Programmer Should Know About Ruby Really Getting Started in Rails Off the Treadmill, Onto the Rails Rails 0.9.5: A world of fixes and tweaks Rich clients with Rails and XUL
Documentation on preloading STIs, TimeHelpers improvement...
David Heinemeier Hansson · 2022-12-16 · via Ruby on Rails: Compress the complexity of modern web apps

Friday, December 16, 2022
Posted by Emmanuel Hayford

नमस्ते, This is Emmanuel Hayford with some updates from Rails!

Hide changes to before_committed! behaviour behind config This PR introduces a new configuration option that will enable before_committed! callbacks on all enrolled records in a transaction by default in Rails 7.1. Previously, callbacks were only run on the first copy of a record if there were multiple copies of the same record enrolled in a transaction.

TimeHelpers: include with_usec keyword parameter on travel & freeze too ActiveSupport::Testing::TimeHelpers now accepts a named with_usec argument to freeze_time, travel, and travel_to methods. Passing true prevents truncating the destination time with change(usec: 0).

Allow f.select to be called with a single hash containing options and HTML options select can now be called with a single hash containing options and some HTML options. Previously, this would not work as expected:

<%= select :post, :author, authors, required: true %>

Instead, you needed to do this:

<%= select :post, :author, authors, {}, required: true %>

 Now, either form is accepted, for the following HTML attributes: required, multiple, size.

Fix inconsistent behavior in form helper date/time tags with options DateTime form helpers (time_field, date_field, datetime_field, week_field, month_field) now accept an instance of Time, Date and DateTime as :value option.

Previously we had: <%= form.datetime_field :written_at, value: Time.current.strftime(“%Y-%m-%dT%T”) %>

And now: <%= form.datetime_field :written_at, value: Time.current %>

Document four ways to preload STIs This PR documents a couple of ways to preload STIs. The document is on Edge Rails Guides and you can read all about it.

Thanks to the 26 contributors we had in the last week!

Talk to you next week.

Subscribe to get these updates mailed to you.