Skip to content

Commit

Permalink
Use sinfle file for jsdom types
Browse files Browse the repository at this point in the history
  • Loading branch information
Josehower committed Jun 30, 2023
1 parent c39d258 commit a4be47b
Show file tree
Hide file tree
Showing 2 changed files with 26 additions and 25 deletions.
26 changes: 26 additions & 0 deletions types/base.d.ts → jsdom-napi-rs-canvas.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -461,3 +461,29 @@ declare module 'jsdom-napi-rs-canvas' {
XPathEvaluator: typeof XPathEvaluator;
}
}

// Type definitions for jsdom 21.1
// Project: https://github.com/jsdom/jsdom
// Definitions by: Leonard Thieu <https://github.com/leonard-thieu>
// Johan Palmfjord <https://github.com/palmfjord>
// ExE Boss <https://github.com/ExE-Boss>
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
// Minimum TypeScript Version: 4.5

/// <reference path="base.d.ts"/>

declare module 'jsdom-napi-rs-canvas' {
interface DOMWindow {
FinalizationRegistry: FinalizationRegistryConstructor;
WeakRef: WeakRefConstructor;
InputEvent: typeof InputEvent;
External: typeof External;
}
}

// Necessary to avoid breaking dependents because of the dependency
// on the `ESNext.WeakRef` lib:
// tslint:disable-next-line: no-empty-interface
interface FinalizationRegistryConstructor {}
// tslint:disable-next-line: no-empty-interface
interface WeakRefConstructor {}
25 changes: 0 additions & 25 deletions types/index.d.ts

This file was deleted.

0 comments on commit a4be47b

Please sign in to comment.