Context
I am developing an R package which contains over a hundred page-long functions grouped into 10 different themes.
Desired behavior
I would like the user to be able to take such themes into consideration when calling functions.
For example, instead of calling foo(), the user would have to do either
load(theme1) # or whatever would be used to load a subgroup of functions
foo()
or something like
theme1$foo()
What I want to prevent the user from doing is directly loading the package and calling the function without taking the theme into consideration, i.e. library(package); foo().
What I have tried
I have used the modules package to accomplish the latter solution in a previous package, but this time around the published version of that package doesn't work very well due to how my functions are interdependent (I've opened a GitHub issue on the topic).
I also thought about coding my own solution, maybe something simple involving the creationg of a sublibrary() function that exports only a few functions at a time, but I didn't get anywhere with that.
Of course, I guess publishing 10 different packages would also technically work, but I think that's too clumsy a solution to consider.
Question
Apart from using modules, is there a way to implement either of the functionalities above?
