railsにbootstrapを導入しようとした結果,requireできないというエラーが発生しています。
bundle exec rails s Traceback (most recent call last): 14: from bin/rails:3:in `<main>' 13: from bin/rails:3:in `load' 12: from /Users/pixel/rails_app/book_log/bin/spring:15:in `<top (required)>' 11: from /Users/pixel/rails_app/book_log/bin/spring:15:in `require' 10: from /Users/pixel/.rbenv/versions/2.6.3/lib/ruby/gems/2.6.0/gems/spring-2.1.0/lib/spring/binstub.rb:11:in `<top (required)>' 9: from /Users/pixel/.rbenv/versions/2.6.3/lib/ruby/gems/2.6.0/gems/spring-2.1.0/lib/spring/binstub.rb:11:in `load' 8: from /Users/pixel/.rbenv/versions/2.6.3/lib/ruby/gems/2.6.0/gems/spring-2.1.0/bin/spring:49:in `<top (required)>' 7: from /Users/pixel/.rbenv/versions/2.6.3/lib/ruby/gems/2.6.0/gems/spring-2.1.0/lib/spring/client.rb:30:in `run' 6: from /Users/pixel/.rbenv/versions/2.6.3/lib/ruby/gems/2.6.0/gems/spring-2.1.0/lib/spring/client/command.rb:7:in `call' 5: from /Users/pixel/.rbenv/versions/2.6.3/lib/ruby/gems/2.6.0/gems/spring-2.1.0/lib/spring/client/rails.rb:28:in `call' 4: from /Users/pixel/.rbenv/versions/2.6.3/lib/ruby/gems/2.6.0/gems/spring-2.1.0/lib/spring/client/rails.rb:28:in `load' 3: from /Users/pixel/rails_app/book_log/bin/rails:8:in `<top (required)>' 2: from /Users/pixel/rails_app/book_log/bin/rails:8:in `require_relative' 1: from /Users/pixel/rails_app/book_log/config/boot.rb:4:in `<top (required)>' /Users/pixel/rails_app/book_log/config/boot.rb:4:in `require': cannot load such file -- bootsnap/setup (LoadError)
環境
Rails 5.2.4
ruby 2.6.3
gemfile
gem ' bootstrap '、'〜> 4.4.1 '
gem ' jquery-rails '
読み込んでいるコード
application.scss @import "bootstrap";
上記の問題の解決方法わかる方いらっしゃいましたら、ぜひご教授ください。
Gemfileを修正した後、bundle install していますか
回答1件
あなたの回答
tips
プレビュー