-
Notifications
You must be signed in to change notification settings - Fork 40
Open
Description
Using the latest TypeScript nightly builds (tested with 6.0.0-dev.20251006
), I see a few errors when using this library:
node_modules/@webgpu/types/dist/index.d.ts:342:6 - error TS2300: Duplicate identifier 'GPUPipelineErrorReason'.
342 type GPUPipelineErrorReason =
~~~~~~~~~~~~~~~~~~~~~~
node_modules/typescript/lib/lib.dom.d.ts:40057:6
40057 type GPUPipelineErrorReason = "internal" | "validation";
~~~~~~~~~~~~~~~~~~~~~~
'GPUPipelineErrorReason' was also declared here.
node_modules/@webgpu/types/dist/index.d.ts:2767:13 - error TS2403: Subsequent variable declarations must have the same type. Variable 'GPUError' must be of type '{ new (): GPUError; prototype: GPUError; }', but here has type '{ new (): never; prototype: GPUError; }'.
2767 declare var GPUError: {
~~~~~~~~
node_modules/typescript/lib/lib.dom.d.ts:12685:13
12685 declare var GPUError: {
~~~~~~~~
'GPUError' was also declared here.
node_modules/typescript/lib/lib.dom.d.ts:40057:6 - error TS2300: Duplicate identifier 'GPUPipelineErrorReason'.
40057 type GPUPipelineErrorReason = "internal" | "validation";
~~~~~~~~~~~~~~~~~~~~~~
node_modules/@webgpu/types/dist/index.d.ts:342:6
342 type GPUPipelineErrorReason =
~~~~~~~~~~~~~~~~~~~~~~
'GPUPipelineErrorReason' was also declared here.
Found 3 errors in 2 files.
I believe this I caused by a conflict with TypeScript's built-in dom library typings. Looks like GPUPipelineErrorReason
and some other types may have been added to the built-in types, possibly with microsoft/TypeScript-DOM-lib-generator#2076
Metadata
Metadata
Assignees
Labels
No labels