mirror of
https://github.com/microsoft/TypeScript.git
synced 2025-11-18 17:21:48 +00:00
json modules should not treated as affecting global scope (#44690)
This commit is contained in:
@@ -570,7 +570,7 @@ namespace ts {
|
||||
*/
|
||||
function isFileAffectingGlobalScope(sourceFile: SourceFile) {
|
||||
return containsGlobalScopeAugmentation(sourceFile) ||
|
||||
!isExternalOrCommonJsModule(sourceFile) && !containsOnlyAmbientModules(sourceFile);
|
||||
!isExternalOrCommonJsModule(sourceFile) && !isJsonSourceFile(sourceFile) && !containsOnlyAmbientModules(sourceFile);
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
+6
-8
@@ -136,7 +136,7 @@ exports.m = common_1["default"];
|
||||
|
||||
|
||||
//// [/out/sub-project/tsconfig.tsbuildinfo]
|
||||
{"program":{"fileNames":["../../lib/lib.d.ts","../../src/common/obj.json","../../src/common/index.d.ts","../../src/sub-project/index.js"],"fileInfos":[{"version":"-32082413277-/// <reference no-default-lib=\"true\"/>\ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array<T> { length: number; [n: number]: T; }\ninterface ReadonlyArray<T> {}\ndeclare const console: { log(msg: any): void; };\ninterface SymbolConstructor {\n readonly species: symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\n","affectsGlobalScope":true},{"version":"2151907832-{\n \"val\": 42\n}","affectsGlobalScope":true},"-4085459678-import x = require(\"./obj.json\");\r\nexport = x;\r\n","-14684157955-import mod from '../common';\n\nexport const m = mod;\n"],"options":{"composite":true,"declaration":true,"esModuleInterop":true,"outDir":"..","rootDir":"../../src","skipLibCheck":true},"fileIdsList":[[2],[3]],"referencedMap":[[3,1],[4,2]],"exportedModulesMap":[[3,1],[4,2]],"semanticDiagnosticsPerFile":[1,3,2,4]},"version":"FakeTSVersion"}
|
||||
{"program":{"fileNames":["../../lib/lib.d.ts","../../src/common/obj.json","../../src/common/index.d.ts","../../src/sub-project/index.js"],"fileInfos":[{"version":"-32082413277-/// <reference no-default-lib=\"true\"/>\ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array<T> { length: number; [n: number]: T; }\ninterface ReadonlyArray<T> {}\ndeclare const console: { log(msg: any): void; };\ninterface SymbolConstructor {\n readonly species: symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\n","affectsGlobalScope":true},"2151907832-{\n \"val\": 42\n}","-4085459678-import x = require(\"./obj.json\");\r\nexport = x;\r\n","-14684157955-import mod from '../common';\n\nexport const m = mod;\n"],"options":{"composite":true,"declaration":true,"esModuleInterop":true,"outDir":"..","rootDir":"../../src","skipLibCheck":true},"fileIdsList":[[2],[3]],"referencedMap":[[3,1],[4,2]],"exportedModulesMap":[[3,1],[4,2]],"semanticDiagnosticsPerFile":[1,3,2,4]},"version":"FakeTSVersion"}
|
||||
|
||||
//// [/out/sub-project/tsconfig.tsbuildinfo.readable.baseline.txt]
|
||||
{
|
||||
@@ -163,8 +163,7 @@ exports.m = common_1["default"];
|
||||
},
|
||||
"../../src/common/obj.json": {
|
||||
"version": "2151907832-{\n \"val\": 42\n}",
|
||||
"signature": "2151907832-{\n \"val\": 42\n}",
|
||||
"affectsGlobalScope": true
|
||||
"signature": "2151907832-{\n \"val\": 42\n}"
|
||||
},
|
||||
"../../src/common/index.d.ts": {
|
||||
"version": "-4085459678-import x = require(\"./obj.json\");\r\nexport = x;\r\n",
|
||||
@@ -207,7 +206,7 @@ exports.m = common_1["default"];
|
||||
]
|
||||
},
|
||||
"version": "FakeTSVersion",
|
||||
"size": 1337
|
||||
"size": 1299
|
||||
}
|
||||
|
||||
//// [/out/sub-project-2/index.d.ts]
|
||||
@@ -303,7 +302,7 @@ module.exports = x;
|
||||
|
||||
|
||||
//// [/src/common/tsconfig.tsbuildinfo]
|
||||
{"program":{"fileNames":["../../lib/lib.d.ts","./obj.json","./index.ts"],"fileInfos":[{"version":"-32082413277-/// <reference no-default-lib=\"true\"/>\ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array<T> { length: number; [n: number]: T; }\ninterface ReadonlyArray<T> {}\ndeclare const console: { log(msg: any): void; };\ninterface SymbolConstructor {\n readonly species: symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\n","affectsGlobalScope":true},{"version":"2151907832-{\n \"val\": 42\n}","affectsGlobalScope":true},"-5032674136-import x = require(\"./obj.json\");\nexport = x;\n"],"options":{"composite":true,"declaration":true,"esModuleInterop":true,"outDir":"../..","rootDir":"..","skipLibCheck":true},"fileIdsList":[[2]],"referencedMap":[[3,1]],"exportedModulesMap":[[3,1]],"semanticDiagnosticsPerFile":[1,3,2]},"version":"FakeTSVersion"}
|
||||
{"program":{"fileNames":["../../lib/lib.d.ts","./obj.json","./index.ts"],"fileInfos":[{"version":"-32082413277-/// <reference no-default-lib=\"true\"/>\ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array<T> { length: number; [n: number]: T; }\ninterface ReadonlyArray<T> {}\ndeclare const console: { log(msg: any): void; };\ninterface SymbolConstructor {\n readonly species: symbol;\n readonly toStringTag: symbol;\n}\ndeclare var Symbol: SymbolConstructor;\ninterface Symbol {\n readonly [Symbol.toStringTag]: string;\n}\n","affectsGlobalScope":true},"2151907832-{\n \"val\": 42\n}","-5032674136-import x = require(\"./obj.json\");\nexport = x;\n"],"options":{"composite":true,"declaration":true,"esModuleInterop":true,"outDir":"../..","rootDir":"..","skipLibCheck":true},"fileIdsList":[[2]],"referencedMap":[[3,1]],"exportedModulesMap":[[3,1]],"semanticDiagnosticsPerFile":[1,3,2]},"version":"FakeTSVersion"}
|
||||
|
||||
//// [/src/common/tsconfig.tsbuildinfo.readable.baseline.txt]
|
||||
{
|
||||
@@ -326,8 +325,7 @@ module.exports = x;
|
||||
},
|
||||
"./obj.json": {
|
||||
"version": "2151907832-{\n \"val\": 42\n}",
|
||||
"signature": "2151907832-{\n \"val\": 42\n}",
|
||||
"affectsGlobalScope": true
|
||||
"signature": "2151907832-{\n \"val\": 42\n}"
|
||||
},
|
||||
"./index.ts": {
|
||||
"version": "-5032674136-import x = require(\"./obj.json\");\nexport = x;\n",
|
||||
@@ -359,6 +357,6 @@ module.exports = x;
|
||||
]
|
||||
},
|
||||
"version": "FakeTSVersion",
|
||||
"size": 1175
|
||||
"size": 1137
|
||||
}
|
||||
|
||||
|
||||
+3
-4
@@ -93,7 +93,7 @@ exports["default"] = hello_json_1["default"].hello;
|
||||
|
||||
|
||||
//// [/src/dist/tsconfig_withFiles.tsbuildinfo]
|
||||
{"program":{"fileNames":["../../lib/lib.d.ts","../src/hello.json","../src/index.ts"],"fileInfos":[{"version":"3858781397-/// <reference no-default-lib=\"true\"/>\ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array<T> { length: number; [n: number]: T; }\ninterface ReadonlyArray<T> {}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true},{"version":"6651571919-{\n \"hello\": \"world\"\n}","affectsGlobalScope":true},"-27703454282-import hello from \"./hello.json\"\n\nexport default hello.hello"],"options":{"allowSyntheticDefaultImports":true,"composite":true,"esModuleInterop":true,"module":1,"outDir":"./","skipDefaultLibCheck":true},"fileIdsList":[[2]],"referencedMap":[[3,1]],"exportedModulesMap":[[3,1]],"semanticDiagnosticsPerFile":[1,2,3]},"version":"FakeTSVersion"}
|
||||
{"program":{"fileNames":["../../lib/lib.d.ts","../src/hello.json","../src/index.ts"],"fileInfos":[{"version":"3858781397-/// <reference no-default-lib=\"true\"/>\ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array<T> { length: number; [n: number]: T; }\ninterface ReadonlyArray<T> {}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true},"6651571919-{\n \"hello\": \"world\"\n}","-27703454282-import hello from \"./hello.json\"\n\nexport default hello.hello"],"options":{"allowSyntheticDefaultImports":true,"composite":true,"esModuleInterop":true,"module":1,"outDir":"./","skipDefaultLibCheck":true},"fileIdsList":[[2]],"referencedMap":[[3,1]],"exportedModulesMap":[[3,1]],"semanticDiagnosticsPerFile":[1,2,3]},"version":"FakeTSVersion"}
|
||||
|
||||
//// [/src/dist/tsconfig_withFiles.tsbuildinfo.readable.baseline.txt]
|
||||
{
|
||||
@@ -116,8 +116,7 @@ exports["default"] = hello_json_1["default"].hello;
|
||||
},
|
||||
"../src/hello.json": {
|
||||
"version": "6651571919-{\n \"hello\": \"world\"\n}",
|
||||
"signature": "6651571919-{\n \"hello\": \"world\"\n}",
|
||||
"affectsGlobalScope": true
|
||||
"signature": "6651571919-{\n \"hello\": \"world\"\n}"
|
||||
},
|
||||
"../src/index.ts": {
|
||||
"version": "-27703454282-import hello from \"./hello.json\"\n\nexport default hello.hello",
|
||||
@@ -149,6 +148,6 @@ exports["default"] = hello_json_1["default"].hello;
|
||||
]
|
||||
},
|
||||
"version": "FakeTSVersion",
|
||||
"size": 1015
|
||||
"size": 977
|
||||
}
|
||||
|
||||
|
||||
+6
-8
@@ -109,7 +109,7 @@ console.log(foo_json_1.foo);
|
||||
|
||||
|
||||
//// [/src/main/tsconfig.tsbuildinfo]
|
||||
{"program":{"fileNames":["../../lib/lib.d.ts","../strings/foo.json","./index.ts"],"fileInfos":[{"version":"3858781397-/// <reference no-default-lib=\"true\"/>\ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array<T> { length: number; [n: number]: T; }\ninterface ReadonlyArray<T> {}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true},{"version":"4395333385-{\n \"foo\": \"bar baz\"\n}","affectsGlobalScope":true},"-4651661680-import { foo } from '../strings/foo.json';\n\nconsole.log(foo);"],"options":{"composite":true,"esModuleInterop":true,"module":1,"rootDir":"..","strict":true,"target":1},"fileIdsList":[[2]],"referencedMap":[[3,1]],"exportedModulesMap":[[3,1]],"semanticDiagnosticsPerFile":[1,3,2]},"version":"FakeTSVersion"}
|
||||
{"program":{"fileNames":["../../lib/lib.d.ts","../strings/foo.json","./index.ts"],"fileInfos":[{"version":"3858781397-/// <reference no-default-lib=\"true\"/>\ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array<T> { length: number; [n: number]: T; }\ninterface ReadonlyArray<T> {}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true},"4395333385-{\n \"foo\": \"bar baz\"\n}","-4651661680-import { foo } from '../strings/foo.json';\n\nconsole.log(foo);"],"options":{"composite":true,"esModuleInterop":true,"module":1,"rootDir":"..","strict":true,"target":1},"fileIdsList":[[2]],"referencedMap":[[3,1]],"exportedModulesMap":[[3,1]],"semanticDiagnosticsPerFile":[1,3,2]},"version":"FakeTSVersion"}
|
||||
|
||||
//// [/src/main/tsconfig.tsbuildinfo.readable.baseline.txt]
|
||||
{
|
||||
@@ -132,8 +132,7 @@ console.log(foo_json_1.foo);
|
||||
},
|
||||
"../strings/foo.json": {
|
||||
"version": "4395333385-{\n \"foo\": \"bar baz\"\n}",
|
||||
"signature": "4395333385-{\n \"foo\": \"bar baz\"\n}",
|
||||
"affectsGlobalScope": true
|
||||
"signature": "4395333385-{\n \"foo\": \"bar baz\"\n}"
|
||||
},
|
||||
"./index.ts": {
|
||||
"version": "-4651661680-import { foo } from '../strings/foo.json';\n\nconsole.log(foo);",
|
||||
@@ -165,11 +164,11 @@ console.log(foo_json_1.foo);
|
||||
]
|
||||
},
|
||||
"version": "FakeTSVersion",
|
||||
"size": 975
|
||||
"size": 937
|
||||
}
|
||||
|
||||
//// [/src/strings/tsconfig.tsbuildinfo]
|
||||
{"program":{"fileNames":["../../lib/lib.d.ts","./foo.json"],"fileInfos":[{"version":"3858781397-/// <reference no-default-lib=\"true\"/>\ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array<T> { length: number; [n: number]: T; }\ninterface ReadonlyArray<T> {}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true},{"version":"4395333385-{\n \"foo\": \"bar baz\"\n}","affectsGlobalScope":true}],"options":{"composite":true,"esModuleInterop":true,"module":1,"rootDir":"..","strict":true,"target":1},"referencedMap":[],"exportedModulesMap":[],"semanticDiagnosticsPerFile":[1,2]},"version":"FakeTSVersion"}
|
||||
{"program":{"fileNames":["../../lib/lib.d.ts","./foo.json"],"fileInfos":[{"version":"3858781397-/// <reference no-default-lib=\"true\"/>\ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array<T> { length: number; [n: number]: T; }\ninterface ReadonlyArray<T> {}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true},"4395333385-{\n \"foo\": \"bar baz\"\n}"],"options":{"composite":true,"esModuleInterop":true,"module":1,"rootDir":"..","strict":true,"target":1},"referencedMap":[],"exportedModulesMap":[],"semanticDiagnosticsPerFile":[1,2]},"version":"FakeTSVersion"}
|
||||
|
||||
//// [/src/strings/tsconfig.tsbuildinfo.readable.baseline.txt]
|
||||
{
|
||||
@@ -186,8 +185,7 @@ console.log(foo_json_1.foo);
|
||||
},
|
||||
"./foo.json": {
|
||||
"version": "4395333385-{\n \"foo\": \"bar baz\"\n}",
|
||||
"signature": "4395333385-{\n \"foo\": \"bar baz\"\n}",
|
||||
"affectsGlobalScope": true
|
||||
"signature": "4395333385-{\n \"foo\": \"bar baz\"\n}"
|
||||
}
|
||||
},
|
||||
"options": {
|
||||
@@ -206,7 +204,7 @@ console.log(foo_json_1.foo);
|
||||
]
|
||||
},
|
||||
"version": "FakeTSVersion",
|
||||
"size": 843
|
||||
"size": 805
|
||||
}
|
||||
|
||||
|
||||
|
||||
+3
-4
@@ -96,7 +96,7 @@ exports["default"] = hello_json_1["default"].hello;
|
||||
|
||||
|
||||
//// [/src/dist/tsconfig_withIncludeAndFiles.tsbuildinfo]
|
||||
{"program":{"fileNames":["../../lib/lib.d.ts","../src/hello.json","../src/index.ts"],"fileInfos":[{"version":"3858781397-/// <reference no-default-lib=\"true\"/>\ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array<T> { length: number; [n: number]: T; }\ninterface ReadonlyArray<T> {}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true},{"version":"6651571919-{\n \"hello\": \"world\"\n}","affectsGlobalScope":true},"-27703454282-import hello from \"./hello.json\"\n\nexport default hello.hello"],"options":{"allowSyntheticDefaultImports":true,"composite":true,"esModuleInterop":true,"module":1,"outDir":"./","skipDefaultLibCheck":true},"fileIdsList":[[2]],"referencedMap":[[3,1]],"exportedModulesMap":[[3,1]],"semanticDiagnosticsPerFile":[1,2,3]},"version":"FakeTSVersion"}
|
||||
{"program":{"fileNames":["../../lib/lib.d.ts","../src/hello.json","../src/index.ts"],"fileInfos":[{"version":"3858781397-/// <reference no-default-lib=\"true\"/>\ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array<T> { length: number; [n: number]: T; }\ninterface ReadonlyArray<T> {}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true},"6651571919-{\n \"hello\": \"world\"\n}","-27703454282-import hello from \"./hello.json\"\n\nexport default hello.hello"],"options":{"allowSyntheticDefaultImports":true,"composite":true,"esModuleInterop":true,"module":1,"outDir":"./","skipDefaultLibCheck":true},"fileIdsList":[[2]],"referencedMap":[[3,1]],"exportedModulesMap":[[3,1]],"semanticDiagnosticsPerFile":[1,2,3]},"version":"FakeTSVersion"}
|
||||
|
||||
//// [/src/dist/tsconfig_withIncludeAndFiles.tsbuildinfo.readable.baseline.txt]
|
||||
{
|
||||
@@ -119,8 +119,7 @@ exports["default"] = hello_json_1["default"].hello;
|
||||
},
|
||||
"../src/hello.json": {
|
||||
"version": "6651571919-{\n \"hello\": \"world\"\n}",
|
||||
"signature": "6651571919-{\n \"hello\": \"world\"\n}",
|
||||
"affectsGlobalScope": true
|
||||
"signature": "6651571919-{\n \"hello\": \"world\"\n}"
|
||||
},
|
||||
"../src/index.ts": {
|
||||
"version": "-27703454282-import hello from \"./hello.json\"\n\nexport default hello.hello",
|
||||
@@ -152,6 +151,6 @@ exports["default"] = hello_json_1["default"].hello;
|
||||
]
|
||||
},
|
||||
"version": "FakeTSVersion",
|
||||
"size": 1015
|
||||
"size": 977
|
||||
}
|
||||
|
||||
|
||||
+3
-4
@@ -89,7 +89,7 @@ exports["default"] = index_json_1["default"].hello;
|
||||
|
||||
|
||||
//// [/src/dist/tsconfig_withIncludeOfJson.tsbuildinfo]
|
||||
{"program":{"fileNames":["../../lib/lib.d.ts","../src/index.json","../src/index.ts"],"fileInfos":[{"version":"3858781397-/// <reference no-default-lib=\"true\"/>\ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array<T> { length: number; [n: number]: T; }\ninterface ReadonlyArray<T> {}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true},{"version":"-2379406821-{\"hello\":\"world\"}","affectsGlobalScope":true},"-6335882310-import hello from \"./index.json\"\n\nexport default hello.hello"],"options":{"allowSyntheticDefaultImports":true,"composite":true,"esModuleInterop":true,"module":1,"outDir":"./","skipDefaultLibCheck":true},"fileIdsList":[[2]],"referencedMap":[[3,1]],"exportedModulesMap":[[3,1]],"semanticDiagnosticsPerFile":[1,2,3]},"version":"FakeTSVersion"}
|
||||
{"program":{"fileNames":["../../lib/lib.d.ts","../src/index.json","../src/index.ts"],"fileInfos":[{"version":"3858781397-/// <reference no-default-lib=\"true\"/>\ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array<T> { length: number; [n: number]: T; }\ninterface ReadonlyArray<T> {}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true},"-2379406821-{\"hello\":\"world\"}","-6335882310-import hello from \"./index.json\"\n\nexport default hello.hello"],"options":{"allowSyntheticDefaultImports":true,"composite":true,"esModuleInterop":true,"module":1,"outDir":"./","skipDefaultLibCheck":true},"fileIdsList":[[2]],"referencedMap":[[3,1]],"exportedModulesMap":[[3,1]],"semanticDiagnosticsPerFile":[1,2,3]},"version":"FakeTSVersion"}
|
||||
|
||||
//// [/src/dist/tsconfig_withIncludeOfJson.tsbuildinfo.readable.baseline.txt]
|
||||
{
|
||||
@@ -112,8 +112,7 @@ exports["default"] = index_json_1["default"].hello;
|
||||
},
|
||||
"../src/index.json": {
|
||||
"version": "-2379406821-{\"hello\":\"world\"}",
|
||||
"signature": "-2379406821-{\"hello\":\"world\"}",
|
||||
"affectsGlobalScope": true
|
||||
"signature": "-2379406821-{\"hello\":\"world\"}"
|
||||
},
|
||||
"../src/index.ts": {
|
||||
"version": "-6335882310-import hello from \"./index.json\"\n\nexport default hello.hello",
|
||||
@@ -145,6 +144,6 @@ exports["default"] = index_json_1["default"].hello;
|
||||
]
|
||||
},
|
||||
"version": "FakeTSVersion",
|
||||
"size": 1008
|
||||
"size": 970
|
||||
}
|
||||
|
||||
|
||||
+3
-4
@@ -93,7 +93,7 @@ exports["default"] = hello_json_1["default"].hello;
|
||||
|
||||
|
||||
//// [/src/dist/tsconfig_withIncludeOfJson.tsbuildinfo]
|
||||
{"program":{"fileNames":["../../lib/lib.d.ts","../src/hello.json","../src/index.ts"],"fileInfos":[{"version":"3858781397-/// <reference no-default-lib=\"true\"/>\ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array<T> { length: number; [n: number]: T; }\ninterface ReadonlyArray<T> {}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true},{"version":"6651571919-{\n \"hello\": \"world\"\n}","affectsGlobalScope":true},"-27703454282-import hello from \"./hello.json\"\n\nexport default hello.hello"],"options":{"allowSyntheticDefaultImports":true,"composite":true,"esModuleInterop":true,"module":1,"outDir":"./","skipDefaultLibCheck":true},"fileIdsList":[[2]],"referencedMap":[[3,1]],"exportedModulesMap":[[3,1]],"semanticDiagnosticsPerFile":[1,2,3]},"version":"FakeTSVersion"}
|
||||
{"program":{"fileNames":["../../lib/lib.d.ts","../src/hello.json","../src/index.ts"],"fileInfos":[{"version":"3858781397-/// <reference no-default-lib=\"true\"/>\ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array<T> { length: number; [n: number]: T; }\ninterface ReadonlyArray<T> {}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true},"6651571919-{\n \"hello\": \"world\"\n}","-27703454282-import hello from \"./hello.json\"\n\nexport default hello.hello"],"options":{"allowSyntheticDefaultImports":true,"composite":true,"esModuleInterop":true,"module":1,"outDir":"./","skipDefaultLibCheck":true},"fileIdsList":[[2]],"referencedMap":[[3,1]],"exportedModulesMap":[[3,1]],"semanticDiagnosticsPerFile":[1,2,3]},"version":"FakeTSVersion"}
|
||||
|
||||
//// [/src/dist/tsconfig_withIncludeOfJson.tsbuildinfo.readable.baseline.txt]
|
||||
{
|
||||
@@ -116,8 +116,7 @@ exports["default"] = hello_json_1["default"].hello;
|
||||
},
|
||||
"../src/hello.json": {
|
||||
"version": "6651571919-{\n \"hello\": \"world\"\n}",
|
||||
"signature": "6651571919-{\n \"hello\": \"world\"\n}",
|
||||
"affectsGlobalScope": true
|
||||
"signature": "6651571919-{\n \"hello\": \"world\"\n}"
|
||||
},
|
||||
"../src/index.ts": {
|
||||
"version": "-27703454282-import hello from \"./hello.json\"\n\nexport default hello.hello",
|
||||
@@ -149,6 +148,6 @@ exports["default"] = hello_json_1["default"].hello;
|
||||
]
|
||||
},
|
||||
"version": "FakeTSVersion",
|
||||
"size": 1015
|
||||
"size": 977
|
||||
}
|
||||
|
||||
|
||||
@@ -79,7 +79,7 @@ exitCode:: ExitStatus.DiagnosticsPresent_OutputsSkipped
|
||||
|
||||
|
||||
//// [/src/dist/tsconfig_withInclude.tsbuildinfo]
|
||||
{"program":{"fileNames":["../../lib/lib.d.ts","../src/hello.json","../src/index.ts"],"fileInfos":[{"version":"3858781397-/// <reference no-default-lib=\"true\"/>\ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array<T> { length: number; [n: number]: T; }\ninterface ReadonlyArray<T> {}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true},{"version":"6651571919-{\n \"hello\": \"world\"\n}","affectsGlobalScope":true},"-27703454282-import hello from \"./hello.json\"\n\nexport default hello.hello"],"options":{"allowSyntheticDefaultImports":true,"composite":true,"esModuleInterop":true,"module":1,"outDir":"./","skipDefaultLibCheck":true},"fileIdsList":[[2]],"referencedMap":[[3,1]],"exportedModulesMap":[[3,1]],"semanticDiagnosticsPerFile":[1,2,3],"affectedFilesPendingEmit":[[2,1],[3,1]]},"version":"FakeTSVersion"}
|
||||
{"program":{"fileNames":["../../lib/lib.d.ts","../src/hello.json","../src/index.ts"],"fileInfos":[{"version":"3858781397-/// <reference no-default-lib=\"true\"/>\ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array<T> { length: number; [n: number]: T; }\ninterface ReadonlyArray<T> {}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true},"6651571919-{\n \"hello\": \"world\"\n}","-27703454282-import hello from \"./hello.json\"\n\nexport default hello.hello"],"options":{"allowSyntheticDefaultImports":true,"composite":true,"esModuleInterop":true,"module":1,"outDir":"./","skipDefaultLibCheck":true},"fileIdsList":[[2]],"referencedMap":[[3,1]],"exportedModulesMap":[[3,1]],"semanticDiagnosticsPerFile":[1,2,3],"affectedFilesPendingEmit":[[2,1],[3,1]]},"version":"FakeTSVersion"}
|
||||
|
||||
//// [/src/dist/tsconfig_withInclude.tsbuildinfo.readable.baseline.txt]
|
||||
{
|
||||
@@ -102,8 +102,7 @@ exitCode:: ExitStatus.DiagnosticsPresent_OutputsSkipped
|
||||
},
|
||||
"../src/hello.json": {
|
||||
"version": "6651571919-{\n \"hello\": \"world\"\n}",
|
||||
"signature": "6651571919-{\n \"hello\": \"world\"\n}",
|
||||
"affectsGlobalScope": true
|
||||
"signature": "6651571919-{\n \"hello\": \"world\"\n}"
|
||||
},
|
||||
"../src/index.ts": {
|
||||
"version": "-27703454282-import hello from \"./hello.json\"\n\nexport default hello.hello",
|
||||
@@ -145,6 +144,6 @@ exitCode:: ExitStatus.DiagnosticsPresent_OutputsSkipped
|
||||
]
|
||||
},
|
||||
"version": "FakeTSVersion",
|
||||
"size": 1056
|
||||
"size": 1018
|
||||
}
|
||||
|
||||
|
||||
@@ -96,7 +96,7 @@ exports["default"] = hello_json_1["default"].hello;
|
||||
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":";;;;;AAAA,4DAAgC;AAEhC,qBAAe,uBAAK,CAAC,KAAK,CAAA"}
|
||||
|
||||
//// [/src/dist/tsconfig_withFiles.tsbuildinfo]
|
||||
{"program":{"fileNames":["../../lib/lib.d.ts","../src/hello.json","../src/index.ts"],"fileInfos":[{"version":"3858781397-/// <reference no-default-lib=\"true\"/>\ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array<T> { length: number; [n: number]: T; }\ninterface ReadonlyArray<T> {}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true},{"version":"6651571919-{\n \"hello\": \"world\"\n}","affectsGlobalScope":true},"-27703454282-import hello from \"./hello.json\"\n\nexport default hello.hello"],"options":{"allowSyntheticDefaultImports":true,"composite":true,"esModuleInterop":true,"module":1,"outDir":"./","skipDefaultLibCheck":true,"sourceMap":true},"fileIdsList":[[2]],"referencedMap":[[3,1]],"exportedModulesMap":[[3,1]],"semanticDiagnosticsPerFile":[1,2,3]},"version":"FakeTSVersion"}
|
||||
{"program":{"fileNames":["../../lib/lib.d.ts","../src/hello.json","../src/index.ts"],"fileInfos":[{"version":"3858781397-/// <reference no-default-lib=\"true\"/>\ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array<T> { length: number; [n: number]: T; }\ninterface ReadonlyArray<T> {}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true},"6651571919-{\n \"hello\": \"world\"\n}","-27703454282-import hello from \"./hello.json\"\n\nexport default hello.hello"],"options":{"allowSyntheticDefaultImports":true,"composite":true,"esModuleInterop":true,"module":1,"outDir":"./","skipDefaultLibCheck":true,"sourceMap":true},"fileIdsList":[[2]],"referencedMap":[[3,1]],"exportedModulesMap":[[3,1]],"semanticDiagnosticsPerFile":[1,2,3]},"version":"FakeTSVersion"}
|
||||
|
||||
//// [/src/dist/tsconfig_withFiles.tsbuildinfo.readable.baseline.txt]
|
||||
{
|
||||
@@ -119,8 +119,7 @@ exports["default"] = hello_json_1["default"].hello;
|
||||
},
|
||||
"../src/hello.json": {
|
||||
"version": "6651571919-{\n \"hello\": \"world\"\n}",
|
||||
"signature": "6651571919-{\n \"hello\": \"world\"\n}",
|
||||
"affectsGlobalScope": true
|
||||
"signature": "6651571919-{\n \"hello\": \"world\"\n}"
|
||||
},
|
||||
"../src/index.ts": {
|
||||
"version": "-27703454282-import hello from \"./hello.json\"\n\nexport default hello.hello",
|
||||
@@ -153,7 +152,7 @@ exports["default"] = hello_json_1["default"].hello;
|
||||
]
|
||||
},
|
||||
"version": "FakeTSVersion",
|
||||
"size": 1032
|
||||
"size": 994
|
||||
}
|
||||
|
||||
|
||||
|
||||
@@ -80,7 +80,7 @@ exports["default"] = hello_json_1["default"].hello;
|
||||
|
||||
|
||||
//// [/src/tsconfig_withFiles.tsbuildinfo]
|
||||
{"program":{"fileNames":["../lib/lib.d.ts","./src/hello.json","./src/index.ts"],"fileInfos":[{"version":"3858781397-/// <reference no-default-lib=\"true\"/>\ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array<T> { length: number; [n: number]: T; }\ninterface ReadonlyArray<T> {}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true},{"version":"6651571919-{\n \"hello\": \"world\"\n}","affectsGlobalScope":true},"-27703454282-import hello from \"./hello.json\"\n\nexport default hello.hello"],"options":{"allowSyntheticDefaultImports":true,"composite":true,"esModuleInterop":true,"module":1,"skipDefaultLibCheck":true},"fileIdsList":[[2]],"referencedMap":[[3,1]],"exportedModulesMap":[[3,1]],"semanticDiagnosticsPerFile":[1,2,3]},"version":"FakeTSVersion"}
|
||||
{"program":{"fileNames":["../lib/lib.d.ts","./src/hello.json","./src/index.ts"],"fileInfos":[{"version":"3858781397-/// <reference no-default-lib=\"true\"/>\ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array<T> { length: number; [n: number]: T; }\ninterface ReadonlyArray<T> {}\ndeclare const console: { log(msg: any): void; };","affectsGlobalScope":true},"6651571919-{\n \"hello\": \"world\"\n}","-27703454282-import hello from \"./hello.json\"\n\nexport default hello.hello"],"options":{"allowSyntheticDefaultImports":true,"composite":true,"esModuleInterop":true,"module":1,"skipDefaultLibCheck":true},"fileIdsList":[[2]],"referencedMap":[[3,1]],"exportedModulesMap":[[3,1]],"semanticDiagnosticsPerFile":[1,2,3]},"version":"FakeTSVersion"}
|
||||
|
||||
//// [/src/tsconfig_withFiles.tsbuildinfo.readable.baseline.txt]
|
||||
{
|
||||
@@ -103,8 +103,7 @@ exports["default"] = hello_json_1["default"].hello;
|
||||
},
|
||||
"./src/hello.json": {
|
||||
"version": "6651571919-{\n \"hello\": \"world\"\n}",
|
||||
"signature": "6651571919-{\n \"hello\": \"world\"\n}",
|
||||
"affectsGlobalScope": true
|
||||
"signature": "6651571919-{\n \"hello\": \"world\"\n}"
|
||||
},
|
||||
"./src/index.ts": {
|
||||
"version": "-27703454282-import hello from \"./hello.json\"\n\nexport default hello.hello",
|
||||
@@ -135,7 +134,7 @@ exports["default"] = hello_json_1["default"].hello;
|
||||
]
|
||||
},
|
||||
"version": "FakeTSVersion",
|
||||
"size": 996
|
||||
"size": 958
|
||||
}
|
||||
|
||||
|
||||
|
||||
-1
@@ -103,7 +103,6 @@ Program files::
|
||||
/user/username/projects/myproject/a.ts
|
||||
|
||||
Semantic diagnostics in builder refreshed for::
|
||||
/a/lib/lib.d.ts
|
||||
/user/username/projects/myproject/data.json
|
||||
/user/username/projects/myproject/a.ts
|
||||
|
||||
|
||||
Reference in New Issue
Block a user