JordanHatch/maslow-redux

View on GitHub
app/views/devise/sessions/new.html.erb

Summary

Maintainability
Test Coverage
<section class="login">
  <h2>Sign in</h2>

  <%= semantic_form_for(resource, as: resource_name, url: session_path(resource_name)) do |f| %>
    <%= f.inputs do %>
      <%= f.input :email, input_html: { autofocus: true } %>
      <%= f.input :password, input_html: { autocomplete: 'off' } %>
      <%= f.input :remember_me, as: :boolean,
                                label: false # This prevents the label from appearing twice
                                %>
    <% end %>

    <%= f.actions do %>
      <%= f.action :submit, label: 'Sign in' %>
    <% end %>
  <% end %>
</section>