Skip to content

Commit 35806fd

Browse files
committed
Clarify that this is the NPM version of TS
1 parent 6f01d40 commit 35806fd

1 file changed

Lines changed: 3 additions & 3 deletions

File tree

packages/types/extract-dom-types.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ import {
1919
SyntaxKind,
2020
TypeAliasDeclaration,
2121
} from 'ts-morph';
22-
import { version } from 'typescript';
22+
import { version as npmVersion } from 'typescript';
2323

2424
// List of types we directly reference from the dom lib. Only interface and type
2525
// alias identifiers are valid, since other syntax types (class, function, var)
@@ -48,7 +48,7 @@ const types = [
4848
const denoDir = new DenoDir();
4949
const domSourcePath = join(
5050
denoDir.root,
51-
`npm/registry.npmjs.org/typescript/${version}/lib/lib.dom.d.ts`,
51+
`npm/registry.npmjs.org/typescript/${npmVersion}/lib/lib.dom.d.ts`,
5252
);
5353

5454
// Check that the file exists
@@ -100,7 +100,7 @@ const outputSourceFile = project.createSourceFile(`src/dom.ts`, undefined, {
100100
outputSourceFile.addStatements([
101101
`// deno-fmt-ignore-file`,
102102
`/**`,
103-
` * Generated from typescript@${version}`,
103+
` * Generated from typescript@${npmVersion}`,
104104
` * To regenerate, run the following command from the package root:`,
105105
` * deno task extract-dom-types`,
106106
` */`,

0 commit comments

Comments
 (0)