I have a gem which has the following Railtie class. I am trying to access my_config variable from outside, i.e another ruby class in the same gem. How can I access it?
module myModule
module Rails
class Railtie < ::Rails::Railtie
initializer 'load_config' do
my_config = "random config here"
puts my_config
end
end
end
end
end
Maybe you can use instance_variable_get: