在使用--webpack = react选项在Rails 5.1中获得项目设置后,应该安装bootstrap gem吗?还是使用毛线加长靴?还是如果我在整个项目中使用Rails并对组件进行反应,是否都需要?
另外,这两种方法都有优点和缺点吗?
我一直在关注Rails应用程序的教程。本教程基于Rails 5,我正在使用Rails 5.1.2。一切都在本地运行良好,并毫无问题地推送至heroku。但是,当我通过运行在生产数据库上创建管理员用户时:
$ heroku run rails c
Run Code Online (Sandbox Code Playgroud)
它返回以下错误:
/app/vendor/bundle/ruby/2.4.0/gems/activesupport-5.1.3/lib/active_support/dependencies.rb:292:
require': cannot load such file -- rack/handler/c (LoadError) from /app/vendor/bundle/ruby/2.4.0/gems/activesupport-5.1.3/lib/active_support/dependencies.rb:292:in在/app/vendor/bundle/ruby/2.4.0/ gems / activesupport-5.1.3 / lib / active_support / dependencies.rb:258:inload_dependency' from /app/vendor/bundle/ruby/2.4.0/gems/activesupport-5.1.3/lib/active_support/dependencies.rb:292:inrequire'来自/app/vendor/bundle/ruby/2.4.0/gems/rack-2.0.3/lib/rack/handler.rb :74:try_require' from /app/vendor/bundle/ruby/2.4.0/gems/rack-2.0.3/lib/rack/handler.rb:16:in从/app/vendor/bundle/ruby/2.4.0/gems/rack-2.0.3/lib/rack/server.rb 中获取:301 :在server' from /app/vendor/bundle/ruby/2.4.0/gems/railties-5.1.3/lib/rails/commands/server/server_command.rb:68:inprint_boot_information中从/ app / vendor / bundle / ruby /2.4.0/gems/railties-5.1.3/lib/rails/commands/server/server_command.rb:38:start' from /app/vendor/bundle/ruby/2.4.0/gems/railties-5.1.3/lib/rails/commands/server/server_command.rb:131:in在/app/vendor/bundle/ruby/2.4.0/gems/railties- 5.1.3 / lib / rails / commands / server / server_command.rb:126:tap' from /app/vendor/bundle/ruby/2.4.0/gems/railties-5.1.3/lib/rails/commands/server/server_command.rb:126:in从/app/vendor/bundle/ruby/2.4.0/gems/thor-0.20.0/lib/thor/command.rb执行:27: 在run' from /app/vendor/bundle/ruby/2.4.0/gems/thor-0.20.0/lib/thor/invocation.rb:126:in来自/app/vendor/bundle/ruby/2.4.0/gems/thor-0.20.0/lib/thor.rb:387:indispatch' from /app/vendor/bundle/ruby/2.4.0/gems/railties-5.1.3/lib/rails/command/base.rb:63:in …