pjk_ok
pjk_ok

Reputation: 947

Delete Snippets File in VS Code

I have a snippets file called tutorials.code-snippets that I would like to delete from VS Code. I can't see anything in the docs that tells you how to delete a custom snippets file. How can I delete it?

Upvotes: 5

Views: 12118

Answers (2)

ms3300
ms3300

Reputation: 296

I did it a bit differently from the anwser above. I directly removed the snippet from the .json file, and I find it a better way to delete the snippet, because you can also look at your other snippets and edit them in the json file, which is more comfortable than just deleting the file. I use the snippet creator by Nikita Kunevich, so maybe if you use a different tool to create snippets they might look differently. Here's how to do it: Click: File > Preferences > User Snippets then such a window will appear: this is the first window

then select the language, for example javascript, and then you will have a window appear: this is the second window (these are my custom snippets)

and here you can basically edit everything to suit your needs, just remeber to hit ctrl+save once you're done!

Upvotes: 0

MarvinJWendt
MarvinJWendt

Reputation: 2684

  1. Open the custom snippet enter image description here
  2. Right click on the tab
  3. Click on Copy Path enter image description here
  4. Open the copied path (Make sure to delete the filename at the end of the path before opening it, or you will open the actual file) enter image description here
  5. Delete the file

Upvotes: 13

Related Questions