You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Is it possible to make yettings load before initializers so that their values may be used in there?
I attempted to fork the repo and change the config.before_configuration to config.before_initialize but it didn't work, which may very well just be because I am not familiar with Railties.
Is this something that would be doable?
My use case is that I want to put the api keys used by devise's devise.rb initializer into a yettings.yml.
The text was updated successfully, but these errors were encountered:
If you're still working off a forked version, instead of doing the config.before_configuration, you can do something like:
initializer "whatevever_you_want_to_call_your_initializer", :before => "name_of_the_initializer_where_you_want_to_use_yettings" do
Yettings.setup!
end
Off the top of my head, I can't think of a good way of adding this into the gem in a reusable way, definitely worth thinking about though. Would be a good feature. You can check out this blogpost for more info on the rails initialization process.
Is it possible to make yettings load before initializers so that their values may be used in there?
I attempted to fork the repo and change the config.before_configuration to config.before_initialize but it didn't work, which may very well just be because I am not familiar with Railties.
Is this something that would be doable?
My use case is that I want to put the api keys used by devise's devise.rb initializer into a yettings.yml.
The text was updated successfully, but these errors were encountered: