diff --git a/js-api-doc/index.d.ts b/js-api-doc/index.d.ts index 02cf87c4..ccf447ed 100644 --- a/js-api-doc/index.d.ts +++ b/js-api-doc/index.d.ts @@ -57,7 +57,7 @@ export { types, } from './legacy/function'; export { - ImporterThis, + LegacyImporterThis, LegacyAsyncImporter, LegacySyncImporter, LegacyImporter, @@ -68,7 +68,7 @@ export { LegacyStringOptions, LegacyOptions, } from './legacy/options'; -export {PluginThis} from './legacy/plugin_this'; +export {LegacyPluginThis} from './legacy/plugin_this'; export {LegacyResult, render, renderSync} from './legacy/render'; export const info: string; diff --git a/js-api-doc/legacy/function.d.ts b/js-api-doc/legacy/function.d.ts index 66d9f3aa..10739df0 100644 --- a/js-api-doc/legacy/function.d.ts +++ b/js-api-doc/legacy/function.d.ts @@ -1,12 +1,12 @@ -import {PluginThis} from './plugin_this'; +import {LegacyPluginThis} from './plugin_this'; export type LegacySyncFunction = ( - this: PluginThis, + this: LegacyPluginThis, ...args: LegacyValue[] ) => LegacyValue; export type LegacyAsyncFunction = ( - this: PluginThis, + this: LegacyPluginThis, ...args: [...LegacyValue[], (type: LegacyValue) => void] ) => void; diff --git a/js-api-doc/legacy/importer.d.ts b/js-api-doc/legacy/importer.d.ts index 0a0e6f93..cfcca648 100644 --- a/js-api-doc/legacy/importer.d.ts +++ b/js-api-doc/legacy/importer.d.ts @@ -1,17 +1,17 @@ -import {PluginThis} from './plugin_this'; +import {LegacyPluginThis} from './plugin_this'; -interface ImporterThis extends PluginThis { +interface LegacyImporterThis extends LegacyPluginThis { fromImport: boolean; } type LegacySyncImporter = ( - this: ImporterThis, + this: LegacyImporterThis, url: string, prev: string ) => {file: string} | {contents: string}; type LegacyAsyncImporter = ( - this: ImporterThis, + this: LegacyImporterThis, url: string, prev: string, done: (data: {file: string} | {contents: string} | Error) => void diff --git a/js-api-doc/legacy/plugin_this.d.ts b/js-api-doc/legacy/plugin_this.d.ts index 407d1d50..12c41547 100644 --- a/js-api-doc/legacy/plugin_this.d.ts +++ b/js-api-doc/legacy/plugin_this.d.ts @@ -1,4 +1,4 @@ -export interface PluginThis { +export interface LegacyPluginThis { options: { file?: string; diff --git a/spec/js-api/index.d.ts b/spec/js-api/index.d.ts index 2cec412e..5561b84a 100644 --- a/spec/js-api/index.d.ts +++ b/spec/js-api/index.d.ts @@ -79,7 +79,7 @@ export { types, } from './legacy/function'; export { - ImporterThis, + LegacyImporterThis, LegacyAsyncImporter, LegacySyncImporter, LegacyImporter, @@ -90,7 +90,7 @@ export { LegacyStringOptions, LegacyOptions, } from './legacy/options'; -export {PluginThis} from './legacy/plugin_this'; +export {LegacyPluginThis} from './legacy/plugin_this'; export {LegacyResult, render, renderSync} from './legacy/render'; /** diff --git a/spec/js-api/legacy/function.d.ts b/spec/js-api/legacy/function.d.ts index 66d9f3aa..10739df0 100644 --- a/spec/js-api/legacy/function.d.ts +++ b/spec/js-api/legacy/function.d.ts @@ -1,12 +1,12 @@ -import {PluginThis} from './plugin_this'; +import {LegacyPluginThis} from './plugin_this'; export type LegacySyncFunction = ( - this: PluginThis, + this: LegacyPluginThis, ...args: LegacyValue[] ) => LegacyValue; export type LegacyAsyncFunction = ( - this: PluginThis, + this: LegacyPluginThis, ...args: [...LegacyValue[], (type: LegacyValue) => void] ) => void; diff --git a/spec/js-api/legacy/importer.d.ts b/spec/js-api/legacy/importer.d.ts index d0ecfe38..25363c31 100644 --- a/spec/js-api/legacy/importer.d.ts +++ b/spec/js-api/legacy/importer.d.ts @@ -1,10 +1,10 @@ -import {PluginThis} from './plugin_this'; +import {LegacyPluginThis} from './plugin_this'; /** * The interface for the `this` keyword for custom importers. The implementation * must invoke importers with an appropriate `this`. */ -interface ImporterThis extends PluginThis { +interface LegacyImporterThis extends LegacyPluginThis { /** * `true` if this importer invocation was caused by an `@import` statement and * `false` otherwise. @@ -16,13 +16,13 @@ interface ImporterThis extends PluginThis { } type LegacySyncImporter = ( - this: ImporterThis, + this: LegacyImporterThis, url: string, prev: string ) => {file: string} | {contents: string}; type LegacyAsyncImporter = ( - this: ImporterThis, + this: LegacyImporterThis, url: string, prev: string, done: (data: {file: string} | {contents: string} | Error) => void diff --git a/spec/js-api/legacy/plugin_this.d.ts b/spec/js-api/legacy/plugin_this.d.ts index 8aca937e..02230d7d 100644 --- a/spec/js-api/legacy/plugin_this.d.ts +++ b/spec/js-api/legacy/plugin_this.d.ts @@ -3,7 +3,7 @@ * functions. The implementation must invoke importers and custom functions with * an appropriate `this`. */ -export interface PluginThis { +export interface LegacyPluginThis { options: { /** The `file` option passed to the `render()` or `renderSync()` call. */ file?: string;