Add an example of ui feedback
raix opened this issue · comments
I've created a debugger for perl, I've used this repo to get started, made things much easier so thanks!
Now I'm facing a challenge where the adapter should communicate to the user eg. "Please install PadWalker for variable inspection to work" - It would be nice to trigger a snackbar in the ui.
Maybe an example on how to do dependency checks on activation and on the fly?
@raix there are basically two approaches for adding UI for a debugger extension:
- return an error from the debug adapter to let user know that he has to install an additional component. This error notification is limited but it supports an optional "Info" link.
- add UI in the debugger extension (not the debug adapter). See https://github.com/Microsoft/vscode-mock-debug/blob/master/src/extension.ts#L24 for how to use a QuickPick UI or https://github.com/Microsoft/vscode-node-debug/blob/master/src/node/extension.ts#L382 for how to hook into the
startSession
command.