Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Can we add image in code comments in VS code

Is it possible to add an image in code comments in VS code? I am working on an angular project. Adding meaningful comments is an important step in the project. Explaining a login in comments in natural language is not effective, however adding an image would help a lot. Is there a way we can add an Image is code comments either directly or thru 3rd party extensions. Please look at the image below. I want the actual image to be visible in the comments rather than a link or a path.

standard png screen shot

like image 632
VIRIYALA NARESH Avatar asked Nov 16 '25 07:11

VIRIYALA NARESH


1 Answers

There is an extension for this: https://marketplace.visualstudio.com/items?itemName=mgiesen.image-comments

Usage:

// Describes the function logic [image-comments/image1.png]

The only way to display an image is to hover over the comment, as it is not possible to place images directly in the code, since it is implemented as a textarea.

like image 156
Krzysztof Avatar answered Nov 17 '25 23:11

Krzysztof