DEV Community

Cover image for Code Annotation: a VSCode extension for adding notes on your code without commiting
professional writer
professional writer

Posted on

Code Annotation: a VSCode extension for adding notes on your code without commiting

Code annotation is a Visual Studio Code extension that creates and tracks annotations from your source code without actually committing comments on your code.

You can download Code Annotation directly from the Marketplace.

Problem Statement

When I’m investigating some bug, or just going through the code for some reason, it’s very common that I came to some realizations:

Oh oh, this code is too strange, this shouldn’t be like this, need to check it later
Damm, this is a horrible name for this method/variable
I need to come back to this function after when popping the calling stack I’m traversing
I need to fix the use of this API here, here, and here (in multiple files)
But because this happens while I’m working on something else, I don’t want to stop, take care of it, and get back. So, what I used to do was either to:

Open my to-do list app, insert an entry on it for the future, and possibly not adding enough context for the future making it a useless entry
Add a not-so-beautiful comment like // DO NOT COMMIT: Thamara check this, which usually lead to me forgetting and committing it anyway (and having to remove, rebase, merge, whatever)
Use of the adding breakpoints feature on VSCode, and frequently losing track of why I tagged something, as well as getting my actual breakpoints all mess up
Needless to say, I needed a better system.

To summarize the problem: I wanted to add some notes that would be tied to a code, but I could include a better description of why I was adding that note. I wanted to track what I added and I didn’t want to commit anything (read: didn’t want to rely on adding TODOs to the code).

I went over several extensions on the VSCode marketplace and could not find anything. So I did the very best thing I do when I have a problem: I solved it myself. If there was no available solution, I would build it.

read more | vscode annotation

Top comments (1)

Collapse
 
marblewraith profile image
Matthew Rath

It exists. It's called Stepsize:

marketplace.visualstudio.com/items...