<%= form_with(model: expense) do |form| %> <% if expense.errors.any? %>

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

<% end %>
<%= form.label :title, style: "display: block" %> <%= form.text_field :title %>
<%= form.label :amount, style: "display: block" %> <%= form.text_field :amount %>
<%= form.label :date, style: "display: block" %> <%= form.date_field :date %>
<%= form.label :category, style: "display: block" %> <%= form.text_field :category %>
<%= form.label :description, style: "display: block" %> <%= form.textarea :description %>
<%= form.submit %>
<% end %>