Rails error_messages helper

This is a very common piece of code.

<% form_for :blah... do |f| %>
<%= f.error_messages %>
First name: <%= f.text_field :first_name %><br />
....
<% end %>

error_messages is a helper method, but it's hard for me to find documentation for it, why?

+3
source share
1 answer

I found them here: error_messages have the same parameters as error_messages_for .

In Rails 3, however, error_messages and error_messages_for were deprecated and were ported to the plugin .

+6
source

Source: https://habr.com/ru/post/1749653/


All Articles