Skip to content

Commit 8b71eb0

Browse files
NetdocsCopilot
andcommitted
docs: document supported syntax-highlighting languages
List the highlight.js common language set plus the infrastructure languages Netdocs registers (powershell, dockerfile, nginx, apache, http, dns, properties, dart, scala, x86asm). Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
1 parent b4eeb8a commit 8b71eb0

1 file changed

Lines changed: 13 additions & 0 deletions

File tree

docs-site/docs/reference/code-blocks.md

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,19 @@ $ netdocs build
3838
```
3939
````
4040

41+
### Supported languages
42+
43+
Highlighting is powered by [highlight.js](https://highlightjs.org/) and covers all of its
44+
["common" languages](https://github.com/highlightjs/highlight.js/blob/main/SUPPORTED_LANGUAGES.md)
45+
(Python, JavaScript/TypeScript, C#, Go, Rust, Java, Ruby, PHP, C/C++, JSON, YAML, XML/HTML, CSS,
46+
SQL, Bash/shell, Markdown, and more). Netdocs additionally registers several infrastructure
47+
languages that are not in that common set:
48+
49+
`powershell`, `dockerfile`, `nginx`, `apache`, `http`, `dns` (zone files), `properties` (`.env` /
50+
`.properties`), `dart`, `scala`, and `x86asm`.
51+
52+
Any language highlight.js does not recognise falls back to a plain block rather than erroring.
53+
4154
```
4255
$ netdocs build
4356
```

0 commit comments

Comments
 (0)