squint icon indicating copy to clipboard operation
squint copied to clipboard

Research adding Railtie to get hot reloading

Open dwilkins opened this issue 8 years ago • 1 comments

from a slack message (thanks @chevinbrown)

class MyRailtie < Rails::Railtie
  # Customize the ORM
  config.app_generators.orm :my_railtie_orm

  # Add a to_prepare block which is executed once in production
  # and before each request in development.
  config.to_prepare do
    MyRailtie.setup!
  end
end

Gotta add this to rails plugin gems to get hot-reloading during development.

dwilkins avatar Jul 05 '17 17:07 dwilkins

Another example https://github.com/RolifyCommunity/rolify/blob/master/lib/rolify/railtie.rb

dwilkins avatar Jul 13 '17 12:07 dwilkins