How to Remove References in Visual Studio Code

References allow you to analyze the popularity of a specific function or variable throughout the code file. It provides us with the number of times a particular property is referred to in the code.

But, when we include code snippets in the documentation for a presentation, it is desirable to remove the references as it makes our code look cleaner. This guide will show how to quickly remove references in VS Code. Follow these steps:

  1. From theĀ file menu, select Preferences. Then, from the sub-menu, select Settings.

    Settings
    Launch VS Code Settings.

  2. Under Text-Editor, select the Diff Editor option. Then, uncheck Code Lens.
    Code Lens
    Finally, disable the Code Lens feature.

    Disabling Code Lens will remove references from your code file.

Leave a Comment