diff --git a/cli/types/cypress.d.ts b/cli/types/cypress.d.ts index 4208b20a7257..b795ae1ea924 100644 --- a/cli/types/cypress.d.ts +++ b/cli/types/cypress.d.ts @@ -107,6 +107,11 @@ declare namespace Cypress { fromAutWindow: WindowPosition & { x: number, y: number } } + /** + * The interface for user-defined properties in Window object. + */ + interface ApplicationWindow {} // tslint:disable-line + /** * Several libraries are bundled with Cypress by default. * @@ -2001,7 +2006,7 @@ declare namespace Cypress { }) ``` */ - window(options?: Partial): Chainable + window(options?: Partial): Chainable /** * Scopes all subsequent cy commands to within this element. diff --git a/cli/types/tests/kitchen-sink.ts b/cli/types/tests/kitchen-sink.ts index 75f5b7538c41..add8e6afdb69 100644 --- a/cli/types/tests/kitchen-sink.ts +++ b/cli/types/tests/kitchen-sink.ts @@ -144,7 +144,7 @@ namespace BlobTests { } cy.window().then(window => { - window // $ExpectType Window & typeof globalThis + window // $ExpectType Window & typeof globalThis & ApplicationWindow window.eval('1') })