Load all regions on demand
espen opened this issue · comments
irb(main):001:0> require "holidays"
=> true
irb(main):002:0> Holidays.available_regions
NameError: uninitialized constant Holidays::REGIONS
Is there any way to load all regions in v5 without calling a specific date method?
😱
That is a pretty egregious oversight, isn't it. I apologize!
I will work this week on finding a solution so that you can 'preload' everything if needed so we can satisfy both use cases. Sorry again!
No worries, I'm using the previous version which works perfectly. Thanks for the work on a very useful gem :)
Sorry that this is taking so long! These last two weeks have been really crazy for me, personally, so things have been slower than I would like. I am still investigating this but I'm not entirely sure when I'll have an answer. Thanks for your patience!
@espen Does this new load_all
method work for you? Is the name clear?
@espen Friendly poke! I would like to make sure this kind of method works for your use case before I add it to our API. Once it's in there I won't be able to change/remove it without a major version bump. 😄
Ooof, that's beautiful. Where is that? I'm very jealous. 😃
No worries at all, it's just been sitting. No big deal. Thanks for the feedback!