Categorized with
static site generators
Anchor links are a useful feature for websites that focus mainly on text, such as a project documentation site or a blog. Like when I changed the code blocks style of my site, I went back to the Astro Docs repo to figure out how to add their anchor links to my site, so let me show you what I did to pull it off!
While researching how to add the View Transitions API with Astro, I thought about implementing the same code block style of their documentation because I find the default configuration of Shiki to lack some important features such as insertions. Also, the way the code blocks are presented in the Astro Docs is just beautiful.