This repository was archived by the owner on Apr 21, 2024. It is now read-only.

Description
Problem description:
Right now, independently of whether a dependency as to be resolved asynchronously or not, all of them are resolved as if that was the case. That's inconvenient, as we pay the price of async at runtime even when it's not necessary.
Proposed solution:
- Ideally, when we register a clearly synchronous factory, it should be available through synchronous getters/resolvers.
- When we register an asynchronous factory, it should be available through asynchronous getters/resolvers.
Important:
- If we register a synchronous factory that ends up depending on asynchronous dependencies, it will be exposed only through the asynchronous resolvers.
Final considerations
This might prove to be difficult, not because of the feasibility of designing the types, but because they might end up being too complex for the TSC type cheker.