-
-
Notifications
You must be signed in to change notification settings - Fork 97
/
Copy pathdebug-shims.d.ts
38 lines (35 loc) · 1.56 KB
/
debug-shims.d.ts
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
/* eslint-disable ts/method-signature-style */
// https://github.com/microsoft/vscode-js-debug/blob/main/src/typings/vscode-js-debug.d.ts
declare module '@vscode/js-debug' {
import type * as vscode from 'vscode'
/** @see {IExports.registerDebugTerminalOptionsProvider} */
export interface IDebugTerminalOptionsProvider {
/**
* Called when the user creates a JavaScript Debug Terminal. It's called
* with the options js-debug wants to use to create the terminal. It should
* modify and return the options to use in the terminal.
*
* In order to avoid conflicting with existing logic, participants should
* try to modify options in a additive way. For example prefer appending
* to rather than reading and overwriting `options.env.PATH`.
*/
provideTerminalOptions(options: vscode.TerminalOptions): vscode.ProviderResult<vscode.TerminalOptions>
}
/**
* Defines the exports of the `js-debug` extension. Once you have this typings
* file, these can be acquired in your extension using the following code:
*
* ```
* const jsDebugExt = vscode.extensions.getExtension('ms-vscode.js-debug-nightly')
* || vscode.extensions.getExtension('ms-vscode.js-debug');
* await jsDebugExt.activate()
* const jsDebug: import('@vscode/js-debug').IExports = jsDebug.exports;
* ```
*/
export interface IExports {
/**
* Registers a participant used when the user creates a JavaScript Debug Terminal.
*/
registerDebugTerminalOptionsProvider(provider: IDebugTerminalOptionsProvider): vscode.Disposable
}
}