<%%= form_with(model: <%= singular_table_name %>, local: true) do |form| %> <%% if <%= singular_table_name %>.errors.any? %>

<%%= pluralize(<%= singular_table_name %>.errors.count, "error") %> prohibited this <%= singular_table_name %> from being saved:

<%% end %> <% attributes.each do |attribute| -%>
<% if attribute.password_digest? -%> <%%= form.label :password %> <%%= form.password_field :password, id: :<%= field_id(:password) %> %>
<%%= form.label :password_confirmation %> <%%= form.password_field :password_confirmation, id: :<%= field_id(:password_confirmation) %> %> <% else -%> <%%= form.label :<%= attribute.column_name %> %> <%%= form.<%= attribute.field_type %> :<%= attribute.column_name %>, id: :<%= field_id(attribute.column_name) %> %> <% end -%>
<% end -%>
<%%= form.submit %>
<%% end %>