I feel like this is a stupid question, but anyways...
I want to improve the naming structure inside my provider by grouping functions together (and if possible, relocate the groups to separate files), so I can access them like this (and I want all sub-functions to have direct access to the providers data):
provider.group.someFunction;
Or is there some common practice out there to make something similar? I am trying to find the most clean way to solve this.
I have tried the following:
- creating proxy-providers with an instance of the main provider (this is the best solution I have found yet, but it forces me to use a separate provider for each group)
- creating a class of functions (do not like this solution, because I have to provide the relevant data to the sub functions through arguments)