app/views/libra/_form.html.erb
<%= form_with(model: librum) do |form| %>
<% if librum.errors.any? %>
<div id="error_explanation">
<h2><%= pluralize(librum.errors.count, "error") %> prohibited this librum from being saved:</h2>
<ul>
<% librum.errors.each do |error| %>
<li><%= error.full_message %></li>
<% end %>
</ul>
</div>
<% end %>
<div class="field">
<%= form.label :text %>
<%= form.text_area :text %>
</div>
<div class="field">
<%= form.label :title %>
<%= form.text_field :title %>
</div>
<div class="actions">
<%= form.submit %>
</div>
<% end %>