Skip to main content

4 posts tagged with "docusaurus"

View All Tags

· 6 min read

A feature that I love about docusaurus is that it uses Prism for syntax highlighting. With Prism, there is support for almost every language you can name. There is support for Power Query (M) and DAX thanks to Peter Budai. My current code samples are mainly in Javascript but I will be writing samples in DAX and Power Query so this is an important feature. Here is how I configured Docusaurus to support the additional languages and how to change themes.

· 5 min read

Using environment variables allows us to to store configuration values outside of the source files. During the build, the reference to the environment variable will be replaced with the values specified. The configuration data is the part of the project that can vary between test and production. Storing the configuration values in one place it makes it easy to update the values outside of the source code. As dotenv points out this is based on The Twelve-Factor methodology of storing configuration data separate from the code. I will show how I added environment variables to Docusaurus.

· 14 min read

Static site generators like Hugo and Docusaurus have different levels of support for comment systems. The current version of Docusaurus does not have a built-in commenting system. With Hugo, it depends on whether the theme you are using has added support for additional commenting systems. It could have Disqus, Giscus, or Utterances to name a few. With any of the static site generators, you can customize and add your favorite comment system to it. This involves adding some code and specifying in the front matter that you want comments enabled. Here is how I added comments to Docusaurus for my blog.