title: customize forget password page devise ruby
body: <p>I have an application. I'm using ruby api as back end for the app. I'm using react native as front end. I'm using devise for authentication. We currently have the devise standard forget password page. I want to customize the page and make the page looks better. after my new implementation i get the email and when i click on the forget password link  a blank tab opens up instead of the new page.</p>
  <p>below is the current page.
  <a href="https://i.stack.imgur.com/jb4Oa.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/jb4Oa.png" alt="enter image description here" /></a></p>
  <p>I created view new.html.erb file in the below path
  app/views/devise/passwords/new.html.erb</p>
  <pre><code>&lt;h2&gt;Change your passwordTest&lt;/h2&gt;
  
  &lt;%= form_for(resource, as: resource_name, url: password_path(resource_name), html: { method: :put }) do |f| %&gt;
    &lt;%= render &quot;devise/shared/error_messages&quot;, resource: resource %&gt;
    &lt;%= f.hidden_field :reset_password_token %&gt;
  
    &lt;div class=&quot;field&quot;&gt;
      &lt;%= f.label :password, &quot;New password&quot; %&gt;&lt;br /&gt;
      &lt;% if @minimum_password_length %&gt;
        &lt;em&gt;(&lt;%= @minimum_password_length %&gt; characters minimum)&lt;/em&gt;&lt;br /&gt;
      &lt;% end %&gt;
      &lt;%= f.password_field :password, autofocus: true, autocomplete: &quot;new-password&quot; %&gt;
    &lt;/div&gt;
  
    &lt;div class=&quot;field&quot;&gt;
      &lt;%= f.label :password_confirmation, &quot;Confirm new password&quot; %&gt;&lt;br /&gt;
      &lt;%= f.password_field :password_confirmation, autocomplete: &quot;new-password&quot; %&gt;
    &lt;/div&gt;
  
    &lt;div class=&quot;actions&quot;&gt;
      &lt;%= f.submit &quot;Change my password&quot; %&gt;
    &lt;/div&gt;
  &lt;% end %&gt;
  
  &lt;%= render &quot;devise/shared/links&quot; %&gt;
  </code></pre>
  <p>in the route.rb file, i have the below code</p>
  <pre><code>  devise_for :users, controllers: { registrations: 'users/registrations', sessions: 'users/sessions', invitations: 'users/invitations', confirmations: 'users/confirmations', omniauth_callbacks: 'users/omniauth_callbacks', passwords: 'users/passwords'}
  
  </code></pre>
  <p>here is my passwords_controller.rb
  app/controllers/users/passwords_controller.rb</p>
  <pre><code>class Users::PasswordsController &lt; Devise::PasswordsController
  
  end
  </code></pre>
  <p>here is the development.log logs</p>
  <pre><code>Started GET &quot;/users/password/edit?reset_password_token=[FILTERED]&quot; for ::1 at 2021-02-25 21:29:36 -0700
  Processing by Users::PasswordsController#edit as HTML
    Parameters: {&quot;reset_password_token&quot;=&gt;&quot;[FILTERED]&quot;}
  Completed 204 No Content in 1ms (ActiveRecord: 0.0ms)
  </code></pre>