1 | import * as ts from 'typescript';
|
2 | type Transformer = ts.TransformerFactory<any> | ts.CustomTransformerFactory;
|
3 | type PluginEntry = string | PluginAndOptions;
|
4 | interface PluginAndOptions {
|
5 | name: 'string';
|
6 | options: Record<string, any>;
|
7 | }
|
8 | export interface NestCompilerPlugin {
|
9 | before?: (options?: Record<string, any>, program?: ts.Program) => Transformer;
|
10 | after?: (options?: Record<string, any>, program?: ts.Program) => Transformer;
|
11 | afterDeclarations?: (options?: Record<string, any>, program?: ts.Program) => Transformer;
|
12 | }
|
13 | export interface MultiNestCompilerPlugins {
|
14 | beforeHooks: Array<(program?: ts.Program) => Transformer>;
|
15 | afterHooks: Array<(program?: ts.Program) => Transformer>;
|
16 | afterDeclarationsHooks: Array<(program?: ts.Program) => Transformer>;
|
17 | }
|
18 | export declare class PluginsLoader {
|
19 | load(plugins?: PluginEntry[]): MultiNestCompilerPlugins;
|
20 | }
|
21 | export {};
|