Skip to content

Interface: UseInjectionOptions<T>

Defined in: src/wirestate-lit/consumption/use-injection.ts:16

Represents options for useInjection.

Type Parameters

Type Parameter
T

Properties

injectionId

ts
injectionId: ServiceIdentifier<T>;

Defined in: src/wirestate-lit/consumption/use-injection.ts:32

The service identifier to inject.


once?

ts
optional once?: boolean;

Defined in: src/wirestate-lit/consumption/use-injection.ts:24

Resolve only the first context value.

Remarks

If true, the service will not update when the container context changes. Defaults to false.


value?

ts
optional value?: Optional<T>;

Defined in: src/wirestate-lit/consumption/use-injection.ts:28

Initial value before the service is fetched.