Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .nvmrc
Original file line number Diff line number Diff line change
@@ -1 +1 @@
20
22
Comment thread
kaladinlight marked this conversation as resolved.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@
"@types/lodash": "^4",
"@types/mixpanel-browser": "^2.48.1",
"@types/multicoin-address-validator": "^0",
"@types/node": "^20.10.7",
"@types/node": "^22.13.14",

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Verification agent

🧩 Analysis chain

Bumping @types/node to ^22.13.14: check TS compatibility and potential DOM/Undici type collisions.

Type packages for Node 22 may surface new globals (fetch, Request, Response via undici-types). With TypeScript at ^5.2.2 and DOM libs enabled, projects sometimes hit duplicate identifier issues. Ensure type-check passes without relying on skipLibCheck.

If you encounter issues:

  • Option A (preferred): bump TypeScript to a newer minor (e.g., ^5.6) that aligns well with modern lib typings.
  • Option B: adjust tsconfig libs to avoid conflicting DOM globals if not needed, or enable "skipLibCheck": true as a fallback.

Verification aide:


🏁 Script executed:

#!/bin/bash
set -euo pipefail

echo "Typescript & @types/node versions:"
jq -r '.devDependencies | {typescript, "@types/node"}' package.json

echo
echo "Check for tsconfig lib and skipLibCheck (may appear in multiple tsconfigs):"
fd -a tsconfig*.json | while read -r f; do
  echo "----- $f"
  rg -n -C1 -P '"lib"\s*:|\bskipLibCheck\b' "$f" || true
done

echo
echo "Scan for common collision indicators (Request/Response/fetch in global usage):"
rg -n -C2 -P '\b(fetch|Request|Response|Headers)\b' --type=ts --type=tsx -g '!**/node_modules/**' || true

Length of output: 555


🏁 Script executed:

#!/bin/bash
set -euo pipefail

echo "Detected tsconfig files:"
fd -g 'tsconfig*.json' || true

echo
echo "Checking tsconfig files for 'lib' entries and skipLibCheck:"
fd -g 'tsconfig*.json' | while read -r file; do
  echo "----- $file -----"
  rg -n -C1 -P '"lib"\s*:|\bskipLibCheck\b' "$file" || true
done

echo
echo "Scanning TS/TSX sources for global fetch|Request|Response|Headers usage:"
rg -n -C2 -P '\b(fetch|Request|Response|Headers)\b' --type ts --type tsx -g '!**/node_modules/**' || true

Length of output: 1390


🏁 Script executed:

#!/bin/bash
set -euo pipefail

echo "Scanning TS/TSX sources for global fetch|Request|Response|Headers usage without relying on --type:"
rg -n -C2 -P '\b(fetch|Request|Response|Headers)\b' -g '*.ts' -g '*.tsx' -g '!**/node_modules/**' || true

Length of output: 1569


skipLibCheck suppresses Node 22/DOM type collisions
Your tsconfig files—tsconfig.json, tsconfig.node.json, and scripts/tsconfig.json—all have "skipLibCheck": true, and tsconfig.json includes ["ES2020", "DOM", "DOM.Iterable"], so any duplicate globals (fetch, Request, Response, Headers from undici-types vs. DOM) are currently ignored. If you ever disable skipLibCheck or run a stricter type-check and hit conflicts, consider:

  • Option A (preferred): bump TypeScript to a newer minor (e.g., ^5.6) that aligns with modern lib typings
  • Option B: remove "DOM"/"DOM.Iterable" from tsconfig.json if browser globals aren’t needed in your Node build
  • Option C: keep "skipLibCheck": true as a fallback
🤖 Prompt for AI Agents
In package.json around line 56, the project pins @types/node ^22 while tsconfigs
use skipLibCheck and include DOM libs which can cause duplicate global type
collisions if skipLibCheck is removed; update the TypeScript devDependency to a
newer minor (e.g., bump "typescript" to ^5.6) as the preferred fix so lib
typings align, or alternatively remove "DOM"/"DOM.Iterable" from tsconfig.json
if browser globals are unnecessary for Node, or keep "skipLibCheck": true as a
last-resort fallback; implement the preferred bump in package.json and run a
full type-check to confirm conflicts are resolved.

"@types/pify": "^5.0.0",
"@types/react": "^18.2.43",
"@types/react-dom": "^18.2.17",
Expand Down
20 changes: 18 additions & 2 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -3104,7 +3104,7 @@ __metadata:
languageName: node
linkType: hard

"@types/node@npm:*, @types/node@npm:^20.10.7":
"@types/node@npm:*":
version: 20.10.7
resolution: "@types/node@npm:20.10.7"
dependencies:
Expand All @@ -3120,6 +3120,15 @@ __metadata:
languageName: node
linkType: hard

"@types/node@npm:^22.13.14":
version: 22.17.2
resolution: "@types/node@npm:22.17.2"
dependencies:
undici-types: "npm:~6.21.0"
checksum: 10c0/23cd13aa35da6322a6d66cf4b3a45dbd40764ba726ab8681960270156c3abba776dd8dc173250c467f708d40612ecd725755d7659b775b513904680d5205eaff
languageName: node
linkType: hard

"@types/parse-json@npm:^4.0.0":
version: 4.0.2
resolution: "@types/parse-json@npm:4.0.2"
Expand Down Expand Up @@ -8329,7 +8338,7 @@ __metadata:
"@types/lodash": "npm:^4"
"@types/mixpanel-browser": "npm:^2.48.1"
"@types/multicoin-address-validator": "npm:^0"
"@types/node": "npm:^20.10.7"
"@types/node": "npm:^22.13.14"
"@types/pify": "npm:^5.0.0"
"@types/qrcode": "npm:^1.5.5"
"@types/react": "npm:^18.2.43"
Expand Down Expand Up @@ -9028,6 +9037,13 @@ __metadata:
languageName: node
linkType: hard

"undici-types@npm:~6.21.0":
version: 6.21.0
resolution: "undici-types@npm:6.21.0"
checksum: 10c0/c01ed51829b10aa72fc3ce64b747f8e74ae9b60eafa19a7b46ef624403508a54c526ffab06a14a26b3120d055e1104d7abe7c9017e83ced038ea5cf52f8d5e04
languageName: node
linkType: hard

"unicode-canonical-property-names-ecmascript@npm:^2.0.0":
version: 2.0.0
resolution: "unicode-canonical-property-names-ecmascript@npm:2.0.0"
Expand Down