Documents injecute 1.x · Migrating from 0.x
Skip to content

Interface: ContainerEvents ​

Defined in: src/types.ts:319

Event payloads, by event name. container is a read-only view of the container that emitted it.

Properties ​

add ​

add: object

Defined in: src/types.ts:321

A registration was added (or replaced, with replace: true).

container ​

container: ServiceProvider<any>

key ​

key: ServiceKey

kind ​

kind: RegistrationKind

replace ​

replace: boolean


dispose ​

dispose: object

Defined in: src/types.ts:348

dispose() has released every owned instance.

container ​

container: ServiceProvider<any>


get ​

get: object

Defined in: src/types.ts:340

A service was resolved with get() (also fired for nested dependencies).

container ​

container: ServiceProvider<any>

key ​

key: ServiceKey

value ​

value: unknown


produce ​

produce: object

Defined in: src/types.ts:342

A factory created a new instance.

container ​

container: ServiceProvider<any>

key ​

key: ServiceKey

value ​

value: unknown


replace ​

replace: object

Defined in: src/types.ts:328

A registration was replaced; previous describes the old one.

container ​

container: ServiceProvider<any>

key ​

key: ServiceKey

previous ​

previous: RegistrationInfo


reset ​

reset: object

Defined in: src/types.ts:334

Cached instances were cleared by reset().

container ​

container: ServiceProvider<any>

keys? ​

optional keys?: readonly ServiceKey[]

resetParent ​

resetParent: boolean

Released under the MIT License.