Skip to content

Commit

Permalink
Don't limit Options.logger to Console type (#143)
Browse files Browse the repository at this point in the history
  • Loading branch information
the-ress authored and johnnyreilly committed Aug 10, 2018
1 parent 6eb146f commit 5290364
Showing 1 changed file with 8 additions and 2 deletions.
10 changes: 8 additions & 2 deletions src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,12 @@ const customHooks = {

type Formatter = (message: NormalizedMessage, useColors: boolean) => string;

interface Logger {
error(message?: any): void;
warn(message?: any): void;
info(message?: any): void;
}

interface Options {
tsconfig: string;
tslint: string | true;
Expand All @@ -40,7 +46,7 @@ interface Options {
ignoreDiagnostics: number[];
ignoreLints: string[];
colors: boolean;
logger: Console;
logger: Logger;
formatter: 'default' | 'codeframe' | Formatter;
formatterOptions: any;
silent: boolean;
Expand Down Expand Up @@ -70,7 +76,7 @@ class ForkTsCheckerWebpackPlugin {
watch: string[];
ignoreDiagnostics: number[];
ignoreLints: string[];
logger: Console;
logger: Logger;
silent: boolean;
async: boolean;
checkSyntacticErrors: boolean;
Expand Down

0 comments on commit 5290364

Please sign in to comment.