Skip to content

Upgrade Typescript to 5.9 #6058

@sosnovsky

Description

@sosnovsky

Upgrading to Typescript 5.9 causes some build errors (https://flowcrypt.semaphoreci.com/jobs/fd4acffd-4b9c-4c8a-aed1-0c9864de46f3):

/home/semaphore/git/flowcrypt-browser/extension/js/common/browser/browser.ts (13,42): Type 'string | Uint8Array<ArrayBufferLike>' is not assignable to type 'BlobPart'.
  Type 'Uint8Array<ArrayBufferLike>' is not assignable to type 'BlobPart'.
    Type 'Uint8Array<ArrayBufferLike>' is not assignable to type 'ArrayBufferView<ArrayBuffer>'.
      Types of property 'buffer' are incompatible.
        Type 'ArrayBufferLike' is not assignable to type 'ArrayBuffer'.
          Type 'SharedArrayBuffer' is not assignable to type 'ArrayBuffer'.
            Types of property '[Symbol.toStringTag]' are incompatible.
              Type '"SharedArrayBuffer"' is not assignable to type '"ArrayBuffer"'.
/home/semaphore/git/flowcrypt-browser/extension/js/common/core/crypto/smime/smime-key.ts (110,47): Argument of type 'Uint8Array<ArrayBufferLike>' is not assignable to parameter of type 'string | ArrayBuffer | ByteStringBuffer | ArrayBufferView'.
  Type 'Uint8Array<ArrayBufferLike>' is missing the following properties from type 'ByteStringBuffer': data, read, isEmpty, putByte, and 30 more.
/home/semaphore/git/flowcrypt-browser/extension/js/common/core/crypto/smime/smime-key.ts (154,47): Argument of type 'Uint8Array<ArrayBufferLike>' is not assignable to parameter of type 'string | ArrayBuffer | ByteStringBuffer | ArrayBufferView'.
  Type 'Uint8Array<ArrayBufferLike>' is missing the following properties from type 'ByteStringBuffer': data, read, isEmpty, putByte, and 30 more.
/home/semaphore/git/flowcrypt-browser/extension/js/common/platform/store/encryption-key-store.ts (14,7): Type 'Buf' is not assignable to type 'ArrayBuffer'.
  The types of 'slice(...)[Symbol.toStringTag]' are incompatible between these types.
    Type '"Uint8Array"' is not assignable to type '"ArrayBuffer"'.
/home/semaphore/git/flowcrypt-browser/extension/js/common/platform/store/encryption-key-store.ts (18,5): Type 'Uint8Array<ArrayBufferLike>' is not assignable to type 'ArrayBuffer'.
  The types of 'slice(...)[Symbol.toStringTag]' are incompatible between these types.
    Type '"Uint8Array"' is not assignable to type '"ArrayBuffer"'.

Metadata

Metadata

Type

No type

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions