mirror of
https://github.com/microsoft/vscode.git
synced 2025-12-24 20:26:08 +00:00
css/json/html web: adopt LanguageClient API change (#218060)
This commit is contained in:
committed by
GitHub
parent
1b27e602ed
commit
a28cbc207a
@@ -8,13 +8,6 @@ import { LanguageClientOptions } from 'vscode-languageclient';
|
||||
import { startClient, LanguageClientConstructor, AsyncDisposable } from '../htmlClient';
|
||||
import { LanguageClient } from 'vscode-languageclient/browser';
|
||||
|
||||
declare const Worker: {
|
||||
new(stringUrl: string): any;
|
||||
};
|
||||
declare const TextDecoder: {
|
||||
new(encoding?: string): { decode(buffer: ArrayBuffer): string };
|
||||
};
|
||||
|
||||
let client: AsyncDisposable | undefined;
|
||||
|
||||
// this method is called when vs code is activated
|
||||
@@ -25,7 +18,7 @@ export async function activate(context: ExtensionContext) {
|
||||
worker.postMessage({ i10lLocation: l10n.uri?.toString(false) ?? '' });
|
||||
|
||||
const newLanguageClient: LanguageClientConstructor = (id: string, name: string, clientOptions: LanguageClientOptions) => {
|
||||
return new LanguageClient(id, name, clientOptions, worker);
|
||||
return new LanguageClient(id, name, worker, clientOptions);
|
||||
};
|
||||
|
||||
const timer = {
|
||||
|
||||
@@ -1,7 +1,10 @@
|
||||
{
|
||||
"extends": "../../tsconfig.base.json",
|
||||
"compilerOptions": {
|
||||
"outDir": "./out"
|
||||
"outDir": "./out",
|
||||
"lib": [
|
||||
"webworker"
|
||||
]
|
||||
},
|
||||
"include": [
|
||||
"src/**/*",
|
||||
|
||||
Reference in New Issue
Block a user