From 2007d0ea35b7918a407cae48fd57feaebbfa19d1 Mon Sep 17 00:00:00 2001 From: Sergey Solomentsev Date: Thu, 29 Mar 2018 11:37:34 +0300 Subject: [PATCH] Renamed Base class to Generator so to follow latest yeoman API. --- types/yeoman-generator/index.d.ts | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/types/yeoman-generator/index.d.ts b/types/yeoman-generator/index.d.ts index 9db6a70946..a996185516 100644 --- a/types/yeoman-generator/index.d.ts +++ b/types/yeoman-generator/index.d.ts @@ -11,7 +11,7 @@ import * as inquirer from 'inquirer'; type Callback = (err: any) => void; -declare namespace Base { +declare namespace Generator { interface Question extends inquirer.Question { /** * whether to store the user's previous answer @@ -79,7 +79,7 @@ declare namespace Base { } } -declare class Base extends EventEmitter { +declare class Generator extends EventEmitter { constructor(args: string|string[], options: {}); env: { @@ -89,18 +89,18 @@ declare class Base extends EventEmitter { resolved: string; description: string; appname: string; - config: Base.Storage; - fs: Base.MemFsEditor; + config: Generator.Storage; + fs: Generator.MemFsEditor; options: {}; log(message?: string, context?: any): void; - argument(name: string, config: Base.ArgumentConfig): this; + argument(name: string, config: Generator.ArgumentConfig): this; composeWith(namespace: string, options: { [name: string]: any }, settings?: { local: string, link: 'weak'|'strong' }): this; destinationPath(...path: string[]): string; destinationRoot(rootPath?: string): string; determineAppname(): string; - option(name: string, config: Base.OptionConfig): this; - prompt(questions: Base.Questions): Promise; + option(name: string, config: Generator.OptionConfig): this; + prompt(questions: Generator.Questions): Promise; registerTransformStream(stream: {}|Array<{}>): this; rootGeneratorName(): string; rootGeneratorVersion(): string; @@ -149,7 +149,7 @@ declare class Base extends EventEmitter { * * @return Resolved if install successful, rejected otherwise */ - installDependencies(options?: Base.InstallOptions): Promise; + installDependencies(options?: Generator.InstallOptions): Promise; /** * Receives a list of `packages` and an `options` object to install through npm. * @@ -214,4 +214,4 @@ declare class Base extends EventEmitter { } }; } -export = Base; +export = Generator; \ No newline at end of file