This project uses MarkBind for developer documentation. MarkBind is used to create a static site, and can parse markdown, GitHub Flavoured Markdown, and more.
All the commands in this document are assumed to be run from the /docs
folder, unless specified otherwise.
- Install
Node.js
(minimum version 12). - Run
npm ci
to install the necessary tools to build documentation, including MarkBind.
Install the following additional dependencies required by MarkBind to generate PlantUML diagrams locally:
- Install Java 8 or later.
- Install Graphviz v2.38 (or later).
You can also use a globally installed MarkBind if you have one. Make sure to use version 3.*.*
.
Run the following command to view the site locally:
npm run serve
# Alternative if you wish to use a globally installed MarkBind
markbind serve
The live preview will be available at localhost:8080
by default and should update automatically to reflect changes you make to the docs. If you wish to use another port (e.g. 8090
), use the -p
flag as follows:
npm run serve -- -p 8090
markbind serve -p 8090
Working with a MarkBind page is almost exactly the same as working with a standard Markdown page, with the following additional pointers:
- You may want to add
<frontmatter>
code block at the top of the page. For example, settingtitle
allows for the page to be titled as such instead of following the file name. Refer here for more details.<frontmatter> title: "YOUR TITLE HERE" </frontmatter>
- If you are adding a new page and want to include it in the site navigation, you can do so by including the link at the appropriate location in
_markbind/layouts/default.md
. - You can take advantage of MarkBind's additional features such as:
You can refer to MarkBind user guide for more information.
Documentation is automatically deployed after each push to master
branch, as configured in dev-docs.yml
. For more details, refer here.