dt-app
Version:
The Dynatrace App Toolkit is a tool you can use from your command line to create, develop, and deploy apps on your Dynatrace environment.
25 lines (24 loc) • 890 B
TypeScript
import type { ResolvedCliOptions } from '../utils/config/cli-options';
import type { FastifyInstance } from 'fastify';
export type BeforeBuildHook = 'before-build';
export type BeforeServeHook = 'before-serve';
export type Hook = BeforeBuildHook | BeforeServeHook;
export type NamedCallBackHook<T> = {
callBack: T;
name: string;
};
/**
* Callback function to be applied before the build
* @internal
* @experimental
* @deprecated Use _BeforeBuildCallback instead
*/
export type BeforeBuildCallback = (appOptions: ResolvedCliOptions) => void | Promise<void>;
/**
* Callback function to be applied before serving
* @internal
* @experimental
* @deprecated Use _BeforeServeCallBack instead
*/
export type BeforeServeCallBack = (appOptions: ResolvedCliOptions, fastify: FastifyInstance) => void | Promise<void>;
export type CallBack = BeforeBuildCallback | BeforeServeCallBack;