Skip to content

Commit

Permalink
chore(tsconfig): remove dom types (#12192)
Browse files Browse the repository at this point in the history
  • Loading branch information
SimenB authored Dec 29, 2021
1 parent 523fa7e commit 5706d71
Show file tree
Hide file tree
Showing 4 changed files with 30 additions and 5 deletions.
1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -153,6 +153,7 @@
"@testing-library/dom/pretty-format": "26.6.1",
"@types/jest/jest-diff": "^25.1.0",
"@types/jest/pretty-format": "^25.1.0",
"@types/jsdom": "patch:@types/jsdom@*#./patches/@types-jsdom.patch",
"babel-jest": "workspace:*",
"jest": "workspace:*",
"jest-environment-node": "workspace:*",
Expand Down
13 changes: 13 additions & 0 deletions patches/@types-jsdom.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
diff --git a/base.d.ts b/base.d.ts
index fcfed640a5652394461bc49cc426c1119eef2635..acce8ed3958e575427a705c3dcba2b7114ab1ad8 100755
--- a/base.d.ts
+++ b/base.d.ts
@@ -71,7 +71,7 @@ declare module "jsdom" {
sendTo(console: Console, options?: VirtualConsoleSendToOptions): this;
}

- type BinaryData = ArrayBufferLike | NodeJS.ArrayBufferView;
+ type BinaryData = ArrayBufferLike;
interface BaseOptions {
/**
* referrer just affects the value read from document.referrer.
2 changes: 1 addition & 1 deletion tsconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"extends": "@tsconfig/node10/tsconfig.json",
"compilerOptions": {
// Object.fromEntries
"lib": ["dom", "es2019.object"],
"lib": ["es2019.object"],
"declaration": true,
"composite": true,
"emitDeclarationOnly": true,
Expand Down
19 changes: 15 additions & 4 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -4718,14 +4718,25 @@ __metadata:
languageName: node
linkType: hard

"@types/jsdom@npm:^16.2.4":
version: 16.2.7
resolution: "@types/jsdom@npm:16.2.7"
"@types/jsdom@*":
version: 16.2.14
resolution: "@types/jsdom@npm:16.2.14"
dependencies:
"@types/node": "*"
"@types/parse5": "*"
"@types/tough-cookie": "*"
checksum: 2acc361cf2aea5a13d78c3d9e63f4101f19ed02d202d6c870279dc51aa06c1f4e060a52322f9dcd660653334f890ccb3c594c23fc714cb3edf3b8641c7c66565
checksum: ff0c6c17c9a499c8444808874ac8d731fea90a5fc909ecdbd38145a7ce47a8fa3d2b2d26f2389a6061d6e19df9e27bde88613d65c48d3689fe1bc0ba451fb6e0
languageName: node
linkType: hard

"@types/jsdom@patch:@types/jsdom@*#./patches/@types-jsdom.patch::locator=%40jest%2Fmonorepo%40workspace%3A.":
version: 16.2.14
resolution: "@types/jsdom@patch:@types/jsdom@npm%3A16.2.14#./patches/@types-jsdom.patch::version=16.2.14&hash=f9e5dd&locator=%40jest%2Fmonorepo%40workspace%3A."
dependencies:
"@types/node": "*"
"@types/parse5": "*"
"@types/tough-cookie": "*"
checksum: fdcf637b490d478f282744cdd86a33bd76e5001f6437d01f2fdb805b6f1b3b1a5faed1f628aada0ffeca1e69c25d0b4994345b553ac3d25c02a1739517ce6b24
languageName: node
linkType: hard

Expand Down

0 comments on commit 5706d71

Please sign in to comment.