Metadata
aliases: []
shorthands: {}
created: 2022-01-10 04:16:53
modified: 2022-01-11 17:54:51
When writing notes with Foam, with the setting Edit: Link Reference Definitions not turned off, Foam automatically generates some link definitions to the bottom of the files. Also, running Foam Janitor on the command palette generates this for every file in the vault.

These are useful, because they make the notes usable with Jekyll and GitHub Pages, but they can also be very annoying and removing them for hundreds of files can be an impossible task. Luckily, they can be all found using this regex in VSCode:
\[//begin\]: # "Autogenerated link references for markdown compatibility"((.|\n)*)\n\[//end\]: # "Autogenerated link references"