Obsidian for collecting code snippets?

I am planning to learn a few programming languages, and I would like to use Obsidan to organize my code snippets and personal notes on programming.

For the moment I just paste each code snippets into a Zettelkasten and tag it with a few clues. It works fine, but I am curious if anyone in this forum have found a better or more productive way to use Obsidian when collecting information on programming.

Edit: spelling

3 Likes

Actually Programming >>> Collecting Information on Programming

2 Likes

Actually Programming >>> Collecting Information on Programming

@jujodi: @Negan specifically said they are also placing their own code snippets into notes so not only is gatekeeping unnecessary it is also wrong.

Personally I commend @Negan for seeking to study their coding methods in more detail in a durable manner that enables the gathering of insight into deeper patterns and techniques in order to become a better programmer.

@Negan: Since you are using a zettelkasten approach I recommend using phrase-based titles that capture the fundamental principles whenever possible, and use the note to expand on that principle. For example, instead of just creating a note named Closures perhaps you write a title Use closures to retain access to internal scope after a function exits and then describe them and provide examples within that note. The Closures note can then become an outline of links on the topic, each pointing to another note like the one described.

This is an extremely powerful method of note taking in the zettelkasten environment.

For more info on this type of writing see:

6 Likes