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
This differs from the @LateInject decorator in that the dependency will be resolved the first time it's accessed without needing to call Obsidian.inject(this) explicitly.
API
@Injectable(ApplicationGraph)classInjected{
@LazyInject()foo!: Foo;constructor(){// foo is unresolvedthis.foo.bar();// foo is resolved on demand}}
Implementation
In order to achieve this behavior, the @LazyInject decorator should probably return a Proxy which will resolve the dependency when it's required.
The text was updated successfully, but these errors were encountered:
This differs from the
@LateInject
decorator in that the dependency will be resolved the first time it's accessed without needing to callObsidian.inject(this)
explicitly.API
Implementation
In order to achieve this behavior, the
@LazyInject
decorator should probably return a Proxy which will resolve the dependency when it's required.The text was updated successfully, but these errors were encountered: