You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Debug.assert(nodeIsSynthesized(specifier) && specifier.text === runtimeImportSpecifier, `Expected sourceFile.imports[${jsxImportIndex}] to be the synthesized JSX runtime import`);
32090
+
}
32091
+
const mod = resolveExternalModule(specifier || location!, runtimeImportSpecifier, errorMessage, location!);
32087
32092
const result = mod && mod !== unknownSymbol ? getMergedSymbol(resolveSymbol(mod)) : undefined;
32088
32093
if (links) {
32089
32094
links.jsxImplicitImportContainer = result || false;
@@ -35811,7 +35816,7 @@ export function createTypeChecker(host: TypeCheckerHost): TypeChecker {
35811
35816
}
35812
35817
35813
35818
// In JavaScript files, calls to any identifier 'require' are treated as external module imports
35814
-
if (isInJSFile(node) && shouldResolveJsRequire(compilerOptions) && isCommonJsRequire(node)) {
35819
+
if (isInJSFile(node) && isCommonJsRequire(node)) {
35815
35820
return resolveExternalModuleTypeByLiteral(node.arguments![0] as StringLiteral);
35816
35821
}
35817
35822
@@ -37745,15 +37750,16 @@ export function createTypeChecker(host: TypeCheckerHost): TypeChecker {
Copy file name to clipboardExpand all lines: src/compiler/diagnosticMessages.json
+7-7
Original file line number
Diff line number
Diff line change
@@ -1220,7 +1220,7 @@
1220
1220
"category": "Message",
1221
1221
"code": 1377
1222
1222
},
1223
-
"Top-level 'await' expressions are only allowed when the 'module' option is set to 'es2022', 'esnext', 'system', 'node16', or 'nodenext', and the 'target' option is set to 'es2017' or higher.": {
1223
+
"Top-level 'await' expressions are only allowed when the 'module' option is set to 'es2022', 'esnext', 'system', 'node16', 'nodenext', or 'preserve', and the 'target' option is set to 'es2017' or higher.": {
1224
1224
"category": "Error",
1225
1225
"code": 1378
1226
1226
},
@@ -1424,7 +1424,7 @@
1424
1424
"category": "Error",
1425
1425
"code": 1431
1426
1426
},
1427
-
"Top-level 'for await' loops are only allowed when the 'module' option is set to 'es2022', 'esnext', 'system', 'node16', or 'nodenext', and the 'target' option is set to 'es2017' or higher.": {
1427
+
"Top-level 'for await' loops are only allowed when the 'module' option is set to 'es2022', 'esnext', 'system', 'node16', 'nodenext', or 'preserve', and the 'target' option is set to 'es2017' or higher.": {
1428
1428
"category": "Error",
1429
1429
"code": 1432
1430
1430
},
@@ -3595,15 +3595,15 @@
3595
3595
"category": "Error",
3596
3596
"code": 2820
3597
3597
},
3598
-
"Import assertions are only supported when the '--module' option is set to 'esnext'or 'nodenext'.": {
3598
+
"Import assertions are only supported when the '--module' option is set to 'esnext', 'nodenext', or 'preserve'.": {
3599
3599
"category": "Error",
3600
3600
"code": 2821
3601
3601
},
3602
3602
"Import assertions cannot be used with type-only imports or exports.": {
3603
3603
"category": "Error",
3604
3604
"code": 2822
3605
3605
},
3606
-
"Import attributes are only supported when the '--module' option is set to 'esnext'or 'nodenext'.": {
3606
+
"Import attributes are only supported when the '--module' option is set to 'esnext', 'nodenext', or 'preserve'.": {
3607
3607
"category": "Error",
3608
3608
"code": 2823
3609
3609
},
@@ -3683,7 +3683,7 @@
3683
3683
"category": "Error",
3684
3684
"code": 2853
3685
3685
},
3686
-
"Top-level 'await using' statements are only allowed when the 'module' option is set to 'es2022', 'esnext', 'system', 'node16', or 'nodenext', and the 'target' option is set to 'es2017' or higher.": {
3686
+
"Top-level 'await using' statements are only allowed when the 'module' option is set to 'es2022', 'esnext', 'system', 'node16', 'nodenext', or 'preserve', and the 'target' option is set to 'es2017' or higher.": {
3687
3687
"category": "Error",
3688
3688
"code": 2854
3689
3689
},
@@ -4309,7 +4309,7 @@
4309
4309
"category": "Error",
4310
4310
"code": 5070
4311
4311
},
4312
-
"Option '--resolveJsonModule' can only be specified when module code generation is 'commonjs', 'amd', 'es2015' or 'esNext'.": {
4312
+
"Option '--resolveJsonModule' cannot be specified when 'module' is set to 'none', 'system', or 'umd'.": {
4313
4313
"category": "Error",
4314
4314
"code": 5071
4315
4315
},
@@ -4401,7 +4401,7 @@
4401
4401
"category": "Error",
4402
4402
"code": 5094
4403
4403
},
4404
-
"Option '{0}' can only be used when 'module' is set to 'es2015' or later.": {
4404
+
"Option '{0}' can only be used when 'module' is set to 'preserve' or to 'es2015' or later.": {
0 commit comments