Skip to content

Commit de7c1be

Browse files
committed
build: enable verbatimModuleSyntax and erasableSyntaxOnly, bump typescript to latest
1 parent faf6cc7 commit de7c1be

17 files changed

Lines changed: 45 additions & 46 deletions

File tree

packages/codemod-rewrite-module-specifiers-to-full-paths/package.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@
1212
},
1313
"license": "MIT",
1414
"author": "Patrick Kerschbaum <patrick.kerschbaum@gmail.com>",
15+
"type": "module",
1516
"imports": {
1617
"#pkg/*": "./dist/*",
1718
"#pkg-test/*": "./test/*"
@@ -54,7 +55,7 @@
5455
"jscodeshift": "^17.0.0",
5556
"p-limit": "^6.1.0",
5657
"tiny-invariant": "^1.3.3",
57-
"typescript": "^5.8.2"
58+
"typescript": "~5.9.3"
5859
},
5960
"devDependencies": {
6061
"@patricktree/runtime-extensions-node": "workspace:*",

packages/codemod-rewrite-module-specifiers-to-full-paths/src/transform/resolve-module-specifier-to-full-path.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ import path from 'node:path';
22
import invariant from 'tiny-invariant';
33
import ts from 'typescript';
44

5-
import { VisitorContext } from '#pkg/transform/types.js';
5+
import type { VisitorContext } from '#pkg/transform/types.js';
66

77
const tsExtensionToJsExtensionMap = {
88
/* map .d.ts and its variants to just .js */

packages/codemod-rewrite-module-specifiers-to-full-paths/tsconfig.build.json

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -2,16 +2,11 @@
22
"extends": "@patricktree/config-typescript/tsconfig.json",
33
"compilerOptions": {
44
/* Modules */
5-
"module": "node16",
65
"rootDir": "./src",
76
"types": ["node", "ts-expose-internals"],
87

98
/* Emit */
10-
"outDir": "./dist",
11-
12-
/* Interop Constraints */
13-
/* disable "verbatimModuleSyntax" because it is annoying for CJS packages */
14-
"verbatimModuleSyntax": false
9+
"outDir": "./dist"
1510
},
1611
"include": ["src/**/*"]
1712
}
Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,12 @@
11
{
2-
"extends": ["./tsconfig.build.json"],
2+
"extends": [
3+
"./tsconfig.build.json",
4+
"@patricktree/config-typescript/tsconfig.typecheck-only.json",
5+
"@patricktree/config-typescript/tsconfig.runtime-node20.json"
6+
],
37
"compilerOptions": {
48
"rootDir": "."
59
},
610
"include": ["./test/*", "./test/*.json"],
7-
"exclude": ["**/node_modules/**"],
811
"references": [{ "path": "./tsconfig.build.json" }]
912
}

packages/commons-ecma/package.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@
1212
},
1313
"license": "MIT",
1414
"author": "Patrick Kerschbaum <patrick.kerschbaum@gmail.com>",
15+
"type": "module",
1516
"imports": {
1617
"#pkg/*": "./dist/*"
1718
},

packages/commons-ecma/tsconfig.build.json

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -5,11 +5,7 @@
55
"rootDir": "./src",
66

77
/* Emit */
8-
"outDir": "./dist",
9-
10-
/* Interop Constraints */
11-
/* disable "verbatimModuleSyntax" because it is annoying for CJS packages */
12-
"verbatimModuleSyntax": false
8+
"outDir": "./dist"
139
},
1410
"include": ["src/**/*"]
1511
}

packages/commons-node/package.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@
1212
},
1313
"license": "MIT",
1414
"author": "Patrick Kerschbaum <patrick.kerschbaum@gmail.com>",
15+
"type": "module",
1516
"imports": {
1617
"#pkg/*": "./dist/*"
1718
},

packages/commons-node/tsconfig.build.json

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -6,11 +6,7 @@
66
"types": ["node"],
77

88
/* Emit */
9-
"outDir": "./dist",
10-
11-
/* Interop Constraints */
12-
/* disable "verbatimModuleSyntax" because it is annoying for CJS packages */
13-
"verbatimModuleSyntax": false
9+
"outDir": "./dist"
1410
},
1511
"include": ["src/**/*"]
1612
}

packages/runtime-extensions-node/package.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@
1212
},
1313
"license": "MIT",
1414
"author": "Patrick Kerschbaum <patrick.kerschbaum@gmail.com>",
15+
"type": "module",
1516
"imports": {
1617
"#pkg/*": "./dist/*"
1718
},

packages/runtime-extensions-node/tsconfig.build.json

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -6,11 +6,7 @@
66
"types": ["node"],
77

88
/* Emit */
9-
"outDir": "./dist",
10-
11-
/* Interop Constraints */
12-
/* disable "verbatimModuleSyntax" because it is annoying for CJS packages */
13-
"verbatimModuleSyntax": false
9+
"outDir": "./dist"
1410
},
1511
"include": ["src/**/*"]
1612
}

0 commit comments

Comments
 (0)