DEV Community

Cover image for VSCode - Markdown Edition
Kevin Lin for Dendron Inc

Posted on • Originally published at blog.dendron.so

VSCode - Markdown Edition

With the 1.67 release, markdown gains programming language like tooling in VSCode

Specifically:

  • drag and drop files into the editor to create a markdown link
  • find all references to header|links|files|urls inside of markdown
  • rename headers|links inside markdown (and propagate the changes to all places where the link is used)
  • rename markdown files (and propagate changes to all links referencing said file)

If we move past drag and drop, it's notable that all other functions are related to referencing and renaming symbols. These are capabilities that are more commonly associated with programming languages than markdown.

A programming language is any set of rules that converts strings... to various kinds of machine code output

Wikipedia

Programming languages generally have a strict syntax that constrains the language. IDEs leverage this strict syntax to offer features to manipulate symbols within the language.

Markdown also has syntax (albeit more loosely defined) . This makes it possible to introduce similar transformations onto markdown.

The reason that this functionality is useful (and necessary) for programming languages is because codebases today can be massive, surpassing hundreds of millions of lines of code.

Repositories of markdown can also be massive. They are increasingly used to document and store general knowledge - both in the context of personal knowledge management (PKM) and team knowledge management (TKM).

For purposes of illustration - the primary vault (the circle titled private) for the Dendron team has over 400k lines of markdown.

Dendron workspace

The illustartion is generated using a fork of github's repo-visualization code, first described here

Running cloc returns the following output:

cloc --vcs=git .
github.com/AlDanial/cloc v 1.92  T=7.82 s (1472.4 files/s, 65739.6 lines/s)
-------------------------------------------------------------------------------
Language                     files          blank        comment           code
-------------------------------------------------------------------------------
Markdown                     11494         108500             19         404711
JSON                             3              5              0            369
YAML                            14              1              0            351
-------------------------------------------------------------------------------
SUM:                         11511         108506             19         405431
-------------------------------------------------------------------------------
Enter fullscreen mode Exit fullscreen mode

Given the shared syntactical properties and problems of scale between programming languages and markdown, it makes sense that the same tooling can work for both.

VSCode, and IDEs more broadly, help developers manage large code bases by making available tools to leverage and manipulate the syntax of programming languages. By shifting some of this tooling to markdown, can we do the same for large markdown repositories?

Our bet at Dendron is a resounding yes! This is why we built our knowledge management platform inside of VSCode. By leveraging the paradigms from IDEs and applying them to structured markdown, our mission is to help humans manage any amount of information.

Oldest comments (1)

Collapse
 
andrewbaisden profile image
Andrew Baisden

Markdown is so simple and easy to use. I'm pretty sure that I write more Markdown than docx documents these days.