Skip to content

feat: update TypeScript and related packages to latest versions#1188

Merged
streamich merged 2 commits intomasterfrom
copilot/fix-1187
Sep 16, 2025
Merged

feat: update TypeScript and related packages to latest versions#1188
streamich merged 2 commits intomasterfrom
copilot/fix-1187

Conversation

Copy link
Contributor

Copilot AI commented Sep 16, 2025

This PR updates TypeScript and related tooling packages to their latest versions and resolves compatibility issues that arose from the updates.

Changes Made

Package Updates

  • TypeScript: 5.8.35.9.2
  • ts-jest: 29.4.029.4.2
  • ts-loader: 9.5.29.5.4
  • ts-node: 10.9.2 (already latest)
  • tslib: 2.8.1 (already latest)

TypeScript Configuration Updates

Updated tsconfig.json to support modern JavaScript features:

  • Target compilation: es2017es2020
  • Library support: ES2017ES2020
  • Added proper module resolution and type definitions

This enables support for features like BigInt and AsyncIterableIterator that were causing compilation errors.

Type Safety Fixes

Fixed three TypeScript compilation errors related to stricter type checking in the newer version:

  1. Buffer to Uint8Array conversion in FsaNodeSyncWorker.ts:

    // Before: new Uint8Array(buf, buf.byteOffset, buf.byteLength)
    // After: new Uint8Array(buf.buffer, buf.byteOffset, buf.byteLength)
  2. Buffer to BlobPart casting in file handle implementations:

    // Added explicit type assertions for Blob constructor compatibility
    const file = new File([data as BlobPart], this.name, { lastModified: stats.mtime.getTime() });

Verification

  • yarn build completes successfully
  • ✅ All 888 tests pass (out of 907 total, with 19 skipped as expected)
  • ✅ Code formatting is consistent with existing style

The updates maintain full backward compatibility while providing access to the latest TypeScript features and improvements.

Fixes #1187.


💡 You can make Copilot smarter by setting up custom instructions, customizing its development environment and configuring Model Context Protocol (MCP) servers. Learn more Copilot coding agent tips in the docs.

Co-authored-by: streamich <9773803+streamich@users.noreply.github.com>
Copilot AI changed the title [WIP] Update TypeScript feat: update TypeScript and related packages to latest versions Sep 16, 2025
Copilot AI requested a review from streamich September 16, 2025 13:50
@streamich streamich marked this pull request as ready for review September 16, 2025 19:38
@streamich streamich merged commit 3acc707 into master Sep 16, 2025
20 checks passed
@streamich streamich deleted the copilot/fix-1187 branch September 16, 2025 19:40
@github-actions
Copy link
Contributor

🎉 This PR is included in version 4.41.0 🎉

The release is available on:

Your semantic-release bot 📦🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Update TypeScript

2 participants