Adding twitter-bootstrap-rails with an existing rails app

后端 未结 5 485
不思量自难忘°
不思量自难忘° 2021-02-08 00:11

I am trying to use twitter-bootstrap-rails with an existing rails application and getting the following error when i refreshed the page.

no such file to load -- less (

5条回答
  •  深忆病人
    2021-02-08 01:08

    In my case, only re-starting the rails server did not do the trick. I had to do following things to fix the problem.

    1. I needed to install the missing gems first. I added following lines to my Gemfile :

      gem "therubyracer"
      gem "less-rails"
    

    Then in console I ran:

    bundle install
    

    2. Lastly, I had to re-start my rails server.

    After all these steps, twitter bootstrap started working with my rails app. Hope this helps someone who faces the same trouble that I did !

提交回复
热议问题