How to Install Devise

mayas1111

Maya Sheriff

Posted on June 26, 2024

How to Install Devise

Use Devise for Users

Install

rails generate devise:install
Enter fullscreen mode Exit fullscreen mode

Change :delete to :getin devise file

# config/initializers/devise.rb, Line 269

config.sign_out_via = :get
Enter fullscreen mode Exit fullscreen mode

Set a root route in routes

# config/routes.rb

root "boards#index"
Enter fullscreen mode Exit fullscreen mode

Use our new generator supplied by the gem to create the User model and routes

rails generate devise user
Enter fullscreen mode Exit fullscreen mode

Then Migrate

rake  db:migrate
Enter fullscreen mode Exit fullscreen mode
💖 💪 🙅 🚩
mayas1111
Maya Sheriff

Posted on June 26, 2024

Join Our Newsletter. No Spam, Only the good stuff.

Sign up to receive the latest update from our blog.

Related

How to Install Devise
devise How to Install Devise

June 26, 2024