vscode/src/vscode-dts/vscode.proposed.extensionRuntime.d.ts

25 lines
820 B
TypeScript
Raw Normal View History

2024-11-15 06:29:18 +00:00
/*---------------------------------------------------------------------------------------------
* Copyright (c) Microsoft Corporation. All rights reserved.
* Licensed under the MIT License. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/
declare module 'vscode' {
// https://github.com/microsoft/vscode/issues/104436
export enum ExtensionRuntime {
/**
* The extension is running in a NodeJS extension host. Runtime access to NodeJS APIs is available.
*/
Node = 1,
/**
* The extension is running in a Webworker extension host. Runtime access is limited to Webworker APIs.
*/
Webworker = 2
}
export interface ExtensionContext {
readonly extensionRuntime: ExtensionRuntime;
}
}