dino-core
Version:
A dependency injection framework for NodeJS applications
28 lines (27 loc) • 781 B
TypeScript
import { Injectable } from './injectable';
/**
* An component represent the base type for all injectable dependencies and dependent objects.
*
* When contextScan is set to true, classes extending this class will be
* automatically discovered and injected on the application context.
* @typedef {Component}
*
* @public
* @class Component
* @since 0.0.1
*/
export declare class Component extends Injectable {
/**
* Lifecycle hook allows to execute initialization steps for a component behaviour.
*
* @public
*/
postConstruct(): Promise<void> | void;
/**
* Lifecycle hook allows to execute initialization steps for a component behaviour.
*
* @public
*/
preDestroy(): Promise<void> | void;
getTypeName(): string;
}