我只是在探索一种方法,以便从用于开发扩展的 Visual Studio Code API 打开默认浏览器。
以下是我的代码:
var disposable = vscode.commands.registerCommand('extension.browser', () => {
// The code you place here will be executed every time your command is executed
vscode.Uri.call("http://facebook.com");
});
如何使用 vscode 类从 API 打开浏览器 URL。