diff --git a/config/environments/development.rb b/config/environments/development.rb index 90b61895d..cdb296b42 100644 --- a/config/environments/development.rb +++ b/config/environments/development.rb @@ -31,8 +31,9 @@ Rails.application.configure do #config.assets.debug = true config.assets.debug = false - if defined?(Rack::LiveReload) - # Automatically inject JavaScript needed for LiveReload + # Automatically inject JavaScript needed for LiveReload + if ENV['RAKE_LIVE_RELOAD'].present? + require 'rack-livereload' config.middleware.insert_after( ActionDispatch::Static, Rack::LiveReload,