Interface: InjectionOptions<T, F>
Defined in: src/wirestate-lit/consumption/injection.ts:51
Describes options for injection.
Type Parameters
| Type Parameter | Default type |
|---|---|
T | - |
F | undefined |
Properties
fallback?
ts
readonly optional fallback?: InjectionFallback<F>;Defined in: src/wirestate-lit/consumption/injection.ts:68
Value used when the token is not bound. Providing it makes the lookup optional.
Remarks
A function fallback is treated as a factory and receives the active container.
optional?
ts
readonly optional optional?: boolean;Defined in: src/wirestate-lit/consumption/injection.ts:60
Resolve undefined instead of throwing when the token is not bound.
token
ts
readonly token: ServiceToken<T>;Defined in: src/wirestate-lit/consumption/injection.ts:55
The token to inject.