1
0
Fork 0
hugo/docs/content/en/quick-reference/syntax-highlighting-styles.md

1.0 KiB

title description categories keywords
Syntax highlighting styles Highlight code examples using one of these styles.
highlight

Overview

Hugo provides several methods to add syntax highlighting to code examples:

Regardless of method, use any of the syntax highlighting styles below.

Set the default syntax highlighting style in your site configuration:

{{< code-toggle file=hugo >}} [markup.highlight] style = 'monokai' {{< /code-toggle >}}

See configure Markup.

Styles

This gallery demonstrates the application of each syntax highlighting style with code examples written in different programming languages.

{{% syntax-highlighting-styles %}}