Questions tagged [vscode-extensions]

Use this tag for questions about the Visual Studio Code Extension API and extension development. Questions only about extension usage should use the [visual-studio-code] tag instead.

Questions about the Visual Studio Code (VSCode) Extension API and extension development. Questions only about extension usage should use the [visual-studio-code] tag instead.

If you have a question about extension development that isn't a good fit for the Stack Exchange model, use the VS Code Dev Community Slack channel where extension developers help each other out and you can ask questions and find support.

4227 questions
1
vote
0 answers

Caching content of Virtual Documents

I made my TextDocumentContentProvider for virtual documents. I'm generating the content of the file on the go, and it looks like VS Code is caching the content of the file. This is a problem for me. I expect to see a new number in the text of the…
1
vote
1 answer

mypy in vscode consumes too much memory

recently I observed VScode is using an insane amount of memory and after some debugging, I realized it was caused by mypy. Basically, whenever I opened a python file, mypy launched a python process which quickly increases to more than 20G. The issue…
derek
  • 9,358
  • 11
  • 53
  • 94
1
vote
1 answer

I want to Collapse a VSCode tree view programatically

is there any way to collapse the tree view programatically. I want to collapse my tree view when a button is clicked PFA Screenshot. I want Minimise the Firmware Layout View when 'Locate in Project View' is clicked.
1
vote
0 answers

VSCode extension throws regex indices error only when other extension is enabled

Background I am working on an extension (vscode-color-blocks) that uses RegExp match indices (new in ES2022). This means I am using a regex string with the d flag to get indices (relational positions) of each capture group in my regex…
Zoom
  • 400
  • 1
  • 5
  • 20
1
vote
3 answers

How do you add icon/indicators beside TreeView items via VS Code's API?

How can I add decorations beside my TreeItems like how it is done with the built-in git tracker with the M symbol here?:
Neo
  • 77
  • 1
  • 7
1
vote
1 answer

VSCode enable/disable commands in custom TreeView based on properties of node/item

I'm currently working on a custom VSCode extension that fetches data from a remote API and presents the data within a custom tree-view. The treeview itself allows to interact with the API and i.e. filter results based on some predefined criteria…
Roman Vottner
  • 12,213
  • 5
  • 46
  • 63
1
vote
2 answers

VSCode API TreeView not getting children of elements

In providing a treeview to VSCode, it seems to get all the parent elements but fail to get the children of these parent elements, I've added a debug point into it and saw that it was only ever called with undefined, is there something improper with…
Neo
  • 77
  • 1
  • 7
1
vote
0 answers

Sending notification vscode.json-language-features server

My issue in short: I have built an extension, that does additional json validation, completion, definitions. So far - the extension relyed on json schemas in client's settings.json for the main validation. Now I have to make that part dynamic - when…
Wish
  • 1,594
  • 1
  • 18
  • 36
1
vote
1 answer

ANTLR4 how to wait for processing all rules?

I have created my own Xtext based DSL and vscode based editor with language server protocol. I parse the model from the current TextDocument with antlr4ts. Below is the code snippet for the listener class TreeShapeListener implements…
harsh
  • 905
  • 1
  • 10
  • 21
1
vote
0 answers

Locking the pointer to elements in a vscode extension webview panel throws an error

I am building a vscode extension that creates a webview panel. This panel uses threejs to render a 3d scene - this happens successfully. Unfortunately, no matter what I try, I cannot get the pointer to lock to the canvas with the scene and in the…
1
vote
1 answer

How can I add a number bubble to my custom extension icon for my activitybar viewContainer

I'm using the activitybar viewContainer to add a sidebar icon specific to my extension. When you click the icon in the sidebar it opens a view that reveals a list. The list can be updated anytime. I would like the icon to have a number which shows…
agro
  • 13
  • 3
1
vote
0 answers

How to use get-port package from a VS Code extension?

How can I use the get-port package from a VS Code extension? I was able to use get-port in a standalone typescript sample project here, but when I try to use the same tsconfig.json with a VS Code extension I get the following error in the developer…
Håkon Hægland
  • 39,012
  • 21
  • 81
  • 174
1
vote
1 answer

Sourcegraph VSCode - A patternType: filter is required in the query for all saved searches

I am trying to save search query in sourcegraph vscode extension. Name: "Master Search" Query: "context:global repo:^teams/master$ getSiteSettings" Clicked "Add saved search" Error: A patternType: filter is required in the query for all saved…
Rohit
  • 6,365
  • 14
  • 59
  • 90
1
vote
1 answer

SimpleGit library not working with vscode extension

I'm trying to get SimpleGit to work in my vscode extension. To make sure I'm using it properly I created this typescript file import simpleGit, { SimpleGit, CleanOptions } from 'simple-git'; const git: SimpleGit =…
user6680
  • 79
  • 6
  • 34
  • 78
1
vote
0 answers

how to make vscode extension have sound when showInformationMessage appeared?

How can I make showInformationMessage appear with a notification sound, like 'ding'? Is there any typescript code to achieve this?
yijinfang
  • 11
  • 1
1 2 3
99
100