Skip to content

Commit 81d7b98

Browse files
authored
Merge pull request rails#29884 from padi/update_rails_5_upgrade_guide
Updates Rails upgrade guide on `ActionView::Helpers::RecordTagHelper`
2 parents db02760 + ec80bac commit 81d7b98

File tree

2 files changed

+12
-2
lines changed

2 files changed

+12
-2
lines changed

actionview/lib/action_view/helpers/record_tag_helper.rb

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,15 @@
11
module ActionView
22
module Helpers
33
module RecordTagHelper
4-
def div_for(*)
4+
def div_for(*) # :nodoc:
55
raise NoMethodError, "The `div_for` method has been removed from " \
66
"Rails. To continue using it, add the `record_tag_helper` gem to " \
77
"your Gemfile:\n" \
88
" gem 'record_tag_helper', '~> 1.0'\n" \
99
"Consult the Rails upgrade guide for details."
1010
end
1111

12-
def content_tag_for(*)
12+
def content_tag_for(*) # :nodoc:
1313
raise NoMethodError, "The `content_tag_for` method has been removed from " \
1414
"Rails. To continue using it, add the `record_tag_helper` gem to " \
1515
"your Gemfile:\n" \

guides/source/upgrading_ruby_on_rails.md

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -276,6 +276,16 @@ You can now just call the dependency once with a wildcard.
276276
<% # Template Dependency: recordings/threads/events/* %>
277277
```
278278

279+
### `ActionView::Helpers::RecordTagHelper` moved to external gem (record_tag_helper)
280+
281+
`content_tag_for` and `div_for` has been removed in favor of just using `content_tag`. To continue using it, add the `record_tag_helper` gem to your Gemfile:
282+
283+
```ruby
284+
gem 'record_tag_helper', '~> 1.0'
285+
```
286+
287+
See [#18411](https://github.com/rails/rails/pull/18411) for more details.
288+
279289
### Removed Support for `protected_attributes` Gem
280290

281291
The `protected_attributes` gem is no longer supported in Rails 5.

0 commit comments

Comments
 (0)