How to create custom dialog in vscode?

I am developing an extension for vscode and I want to show a user dialog to help the user customize the ini file.
Is it possible to create a custom dialog with labels and inputs?

+6
source share
1 answer

You cannot create new user interface elements, but if you want to receive input from the user, you can use the code as shown below:

let options: InputBoxOptions = { prompt: "Label: ", placeHolder: "(placeholder)" } window.showInputBox(options).then(value => { if (!value) return; answer1 = value; // show the next dialog, etc. }); 

This will use the same user interface as the command palette (when you press ctrl + p or any other command that opens the input window at the top).

+7
source

All Articles