%%= form_with(model: <%= model_resource_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:
<%% <%= singular_table_name %>.errors.full_messages.each do |message| %>
- <%%= message %>
<%% end %>
<%% end %>
<% attributes.each do |attribute| -%>
<% if attribute.password_digest? -%>
<%%= form.label :password %>
<%%= form.password_field :password, class: 'form-control' %>
<%%= form.label :password_confirmation %>
<%%= form.password_field :password_confirmation, class: 'form-control' %>
<% else -%>
<%%= form.label :<%= attribute.column_name %> %>
<%%= form.<%= attribute.field_type %> :<%= attribute.column_name %>, class: 'form-control' %>
<% end -%>
<% end -%>
<%% end %>