<%%= form_with(model: @<%= singular_table_name %>, local: true, class: 'ui form') do |f| %> <%% 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| -%>
<%%= f.label :<%= attribute.name %> %> <%%= f.<%= attribute.field_type %> :<%= attribute.name %> %>
<% end -%>
<%%= f.submit class: 'ui button' %>
<%% end %>