Skip to content
Prev Previous commit
Next Next commit
Rename tsserverWeb to dynamicImportCompat
  • Loading branch information
rbuckton committed Jun 11, 2022
commit 9bc39d17b9ac2af4c31f13826069d6f4f2d2cb7a
16 changes: 8 additions & 8 deletions Gulpfile.js
Original file line number Diff line number Diff line change
Expand Up @@ -214,29 +214,29 @@ task("watch-services").flags = {
" --built": "Compile using the built version of the compiler."
};

const buildServerWeb = () => buildProject("src/tsserverWeb", cmdLineOptions);
task("tsserverWeb", buildServerWeb);
const buildDynamicImportCompat = () => buildProject("src/dynamicImportCompat", cmdLineOptions);
task("dynamicImportCompat", buildDynamicImportCompat);

const buildServerMain = () => buildProject("src/tsserver", cmdLineOptions);
const buildServer = series(buildServerWeb, buildServerMain);
const buildServer = series(buildDynamicImportCompat, buildServerMain);
buildServer.displayName = "buildServer";
task("tsserver", series(preBuild, buildServer));
task("tsserver").description = "Builds the language server";
task("tsserver").flags = {
" --built": "Compile using the built version of the compiler."
};

const cleanServerWeb = () => cleanProject("src/tsserverWeb");
const cleanDynamicImportCompat = () => cleanProject("src/dynamicImportCompat");
const cleanServerMain = () => cleanProject("src/tsserver");
const cleanServer = series(cleanServerWeb, cleanServerMain);
const cleanServer = series(cleanDynamicImportCompat, cleanServerMain);
cleanServer.displayName = "cleanServer";
cleanTasks.push(cleanServer);
task("clean-tsserver", cleanServer);
task("clean-tsserver").description = "Cleans outputs for the language server";

const watchServerWeb = () => watchProject("src/tsserverWeb", cmdLineOptions);
const watchDynamicImportCompat = () => watchProject("src/dynamicImportCompat", cmdLineOptions);
const watchServer = () => watchProject("src/tsserver", cmdLineOptions);
task("watch-tsserver", series(preBuild, parallel(watchLib, watchDiagnostics, watchServerWeb, watchServer)));
task("watch-tsserver", series(preBuild, parallel(watchLib, watchDiagnostics, watchDynamicImportCompat, watchServer)));
task("watch-tsserver").description = "Watch for changes and rebuild the language server only";
task("watch-tsserver").flags = {
" --built": "Compile using the built version of the compiler."
Expand Down Expand Up @@ -558,7 +558,7 @@ const produceLKG = async () => {
"built/local/typescriptServices.js",
"built/local/typescriptServices.d.ts",
"built/local/tsserver.js",
"built/local/tsserverWeb.js",
"built/local/dynamicImportCompat.js",
"built/local/typescript.js",
"built/local/typescript.d.ts",
"built/local/tsserverlibrary.js",
Expand Down
2 changes: 1 addition & 1 deletion scripts/produceLKG.ts
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ async function copyScriptOutputs() {
await copyWithCopyright("cancellationToken.js");
await copyWithCopyright("tsc.release.js", "tsc.js");
await copyWithCopyright("tsserver.js");
await copyWithCopyright("tsserverWeb.js");
await copyWithCopyright("dynamicImportCompat.js");
await copyFromBuiltLocal("tsserverlibrary.js"); // copyright added by build
await copyFromBuiltLocal("typescript.js"); // copyright added by build
await copyFromBuiltLocal("typescriptServices.js"); // copyright added by build
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,9 @@
"lib": ["esnext"],
"declaration": false,
"sourceMap": true,
"tsBuildInfoFile": "../../built/local/tsserverWeb.tsbuildinfo"
"tsBuildInfoFile": "../../built/local/dynamicImportCompat.tsbuildinfo"
},
"files": [
"tsserverWeb.ts",
"dynamicImportCompat.ts",
]
}
2 changes: 1 addition & 1 deletion src/server/editorServices.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4082,7 +4082,7 @@ namespace ts.server {
return;
}

// Otherwise, load the plugin using `resolve`
// Otherwise, load the plugin using `require`
project.endEnablePlugin(project.beginEnablePluginSync(pluginConfigEntry, searchPaths, pluginConfigOverrides));
Comment thread
rbuckton marked this conversation as resolved.
}

Expand Down
2 changes: 1 addition & 1 deletion src/tsconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
{ "path": "./watchGuard" },
{ "path": "./debug" },
{ "path": "./cancellationToken" },
{ "path": "./tsserverWeb" },
{ "path": "./dynamicImportCompat" },
{ "path": "./testRunner" }
]
}
2 changes: 1 addition & 1 deletion src/webServer/webServer.ts
Original file line number Diff line number Diff line change
Expand Up @@ -118,7 +118,7 @@ namespace ts.server {
if (typeof importScripts === "function") {
try {
// NOTE: importScripts is synchronous
importScripts("tsserverWeb.js");
importScripts("dynamicImportCompat.js");
}
catch {
// ignored
Expand Down