1 |
|
2 | import * as childProcess from 'child_process';
|
3 | import { Chalk } from 'chalk';
|
4 | import * as webpack from 'webpack';
|
5 | import { CancellationToken } from './CancellationToken';
|
6 | import { NormalizedMessage } from './NormalizedMessage';
|
7 | import { Message } from './Message';
|
8 | type Formatter = (message: NormalizedMessage, useColors: boolean) => string;
|
9 | interface Logger {
|
10 | error(message?: any): void;
|
11 | warn(message?: any): void;
|
12 | info(message?: any): void;
|
13 | }
|
14 | interface Options {
|
15 | typescript?: string;
|
16 | tsconfig: string;
|
17 | compilerOptions: object;
|
18 | tslint: string | true;
|
19 | watch: string | string[];
|
20 | async: boolean;
|
21 | ignoreDiagnostics: number[];
|
22 | ignoreLints: string[];
|
23 | reportFiles: string[];
|
24 | colors: boolean;
|
25 | logger: Logger;
|
26 | formatter: 'default' | 'codeframe' | Formatter;
|
27 | formatterOptions: any;
|
28 | silent: boolean;
|
29 | checkSyntacticErrors: boolean;
|
30 | memoryLimit: number;
|
31 | workers: number;
|
32 | vue: boolean;
|
33 | }
|
34 |
|
35 |
|
36 |
|
37 |
|
38 |
|
39 |
|
40 |
|
41 | declare class ForkTsCheckerWebpackPlugin {
|
42 | static DEFAULT_MEMORY_LIMIT: number;
|
43 | static ONE_CPU: number;
|
44 | static ALL_CPUS: number;
|
45 | static ONE_CPU_FREE: number;
|
46 | static TWO_CPUS_FREE: number;
|
47 | typescriptPath: string;
|
48 | options: Partial<Options>;
|
49 | tsconfig: string;
|
50 | compilerOptions: object;
|
51 | tslint: string | true;
|
52 | watch: string[];
|
53 | ignoreDiagnostics: number[];
|
54 | ignoreLints: string[];
|
55 | reportFiles: string[];
|
56 | logger: Logger;
|
57 | silent: boolean;
|
58 | async: boolean;
|
59 | checkSyntacticErrors: boolean;
|
60 | workersNumber: number;
|
61 | memoryLimit: number;
|
62 | useColors: boolean;
|
63 | colors: Chalk;
|
64 | formatter: Formatter;
|
65 | tsconfigPath: string;
|
66 | tslintPath: string;
|
67 | watchPaths: string[];
|
68 | compiler: any;
|
69 | started: [number, number];
|
70 | elapsed: [number, number];
|
71 | cancellationToken: CancellationToken;
|
72 | isWatching: boolean;
|
73 | checkDone: boolean;
|
74 | compilationDone: boolean;
|
75 | diagnostics: NormalizedMessage[];
|
76 | lints: NormalizedMessage[];
|
77 | emitCallback: () => void;
|
78 | doneCallback: () => void;
|
79 | typescriptVersion: any;
|
80 | tslintVersion: any;
|
81 | service: childProcess.ChildProcess;
|
82 | vue: boolean;
|
83 | constructor(options?: Partial<Options>);
|
84 | static createFormatter(type: 'default' | 'codeframe', options: any): (message: NormalizedMessage, useColors: boolean) => string;
|
85 | apply(compiler: webpack.Compiler): void;
|
86 | computeContextPath(filePath: string): string;
|
87 | pluginStart(): void;
|
88 | pluginStop(): void;
|
89 | registerCustomHooks(): void;
|
90 | pluginCompile(): void;
|
91 | pluginEmit(): void;
|
92 | pluginDone(): void;
|
93 | spawnService(): void;
|
94 | killService(): void;
|
95 | handleServiceMessage(message: Message): void;
|
96 | handleServiceExit(_code: string | number, signal: string): void;
|
97 | createEmitCallback(compilation: any, callback: () => void): (this: ForkTsCheckerWebpackPlugin) => void;
|
98 | createNoopEmitCallback(): () => void;
|
99 | createDoneCallback(): (this: ForkTsCheckerWebpackPlugin) => void;
|
100 | }
|
101 | export = ForkTsCheckerWebpackPlugin;
|
102 | declare namespace ForkTsCheckerWebpackPlugin {
|
103 | }
|