54
Help us understand the problem. What are the problem?

More than 3 years have passed since last update.

posted at

Rails5でmodelやcontrollerの修正が反映されないやつ

環境

docker for mac
rails5.0
Debian GNU/Linux 8
developmentモード

困ったこと

modelやcontrollerの修正が反映されない。
Viewはすぐに反映される。

解決法1

rails restartしたりコンテナを再起動すれば反映される
(面倒くさ)

解決法2

development.rbに以下を追加

  config.cache_classes = false
  config.reload_classes_only_on_change = false

結果

すぐに反映されるようになった。わーいヾ( ゚д゚)人( ゚д゚)ノ゙

Why not register and get more from Qiita?
  1. We will deliver articles that match you
    By following users and tags, you can catch up information on technical fields that you are interested in as a whole
  2. you can read useful information later efficiently
    By "stocking" the articles you like, you can search right away
54
Help us understand the problem. What are the problem?