Add Devise Bootstrap Views

I just found out about this Devise gem that gives your Devise view pages a much better look. Make sure you already have Devise installed. Since I had already installed the normal Devise views I decided to remove them first, not sure if it makes a difference, however, it worked just fine. So assuming you have already installed the normal Devise views ie. assuming your already ran $ rails g devise:views you can start from the first step below. Otherwise just skip to the second step. You can also go straight to the source by clicking on the link I’ve provided below, it’s a very simple implementation and the author provides clear documentation and it is very easy to follow.

#####Run the following command to remove the devise views if you’ve already installed them

1
$ rails d devise:views

#####Add the gem below to your Gemfile

1
gem 'devise-bootstrap-views'

#####Run the command below

1
$ bundle

#####Open your application.css file and add the code below

1
*= require devise_bootstrap_views

#####Run the following command to install the required translations in your config/locales. Read more …

1
$ rails g devise:views:locale it

#####Run the following command to copy all views to your application. This will allow you to modify your files.
For other templates such as HAML click here scroll down to Customizing Views .

#####If you’re using HAML, like I do, run the following

1
$ rails g devise:views:bootstrap_haml_templates

#####Otherwise run the following for ERB

1
$ rails g devise:views:bootstrap_templates

Learn more about this great time saving gem here Devise Bootstrap Views. If you have any questions or comments, please leave them below.