mirror of
https://github.com/microsoft/TypeScript.git
synced 2025-11-18 17:21:48 +00:00
Generated module conversion step - stripNamespaces
This step converts each file into an exported module by hoisting the namespace bodies into the global scope and transferring internal markers down onto declarations as needed. The namespaces are reconstructed as "barrel"-style modules, which are identical to the old namespace objects in structure. These reconstructed namespaces are then imported in the newly module-ified files, making existing expressions like "ts." valid.
This commit is contained in:
1 parent
9a0b85ce2a
commit
b6c0538826
588 files changed
+4389
-1482
No files matched your search
@@ -0,0 +1,4 @@
|
||||
/* Generated file to emulate the ts namespace. */
|
||||
|
||||
export * from "../../compiler/_namespaces/ts";
|
||||
export * from "../executeCommandLine";
|
||||
@@ -1,4 +1,5 @@
|
||||
namespace ts {
|
||||
import * as ts from "./_namespaces/ts";
|
||||
|
||||
interface Statistic {
|
||||
name: string;
|
||||
value: number;
|
||||
@@ -1207,4 +1208,3 @@ function writeConfigFile(
|
||||
|
||||
return;
|
||||
}
|
||||
}
|
||||
@@ -1,7 +1,7 @@
|
||||
{
|
||||
"extends": "../tsconfig-base",
|
||||
"compilerOptions": {
|
||||
"outFile": "../../built/local/executeCommandLine.js"
|
||||
"outDir": "../../built/local"
|
||||
},
|
||||
|
||||
"references": [
|
||||
@@ -9,6 +9,7 @@
|
||||
],
|
||||
|
||||
"files": [
|
||||
"executeCommandLine.ts"
|
||||
"executeCommandLine.ts",
|
||||
"_namespaces/ts.ts"
|
||||
]
|
||||
}
|
||||
@@ -1,7 +1,7 @@
|
||||
{
|
||||
"extends": "./tsconfig.json",
|
||||
"compilerOptions": {
|
||||
"outFile": "../../built/local/executeCommandLine.release.js",
|
||||
"outDir": "../../built/local/release",
|
||||
"removeComments": true,
|
||||
"preserveConstEnums": false
|
||||
},
|
||||
|
||||
Reference in new issue
Block a user