Math Typesetting
For math typesetting in a Hugo project, you can leverage hugo’s internal rendering engine.
If you want to use mathematical or chemical equations in your site, enable the Goldmark passthrough extension and define delimiters for block and inline formulae in your config file:
hugo.toml
[markup]
[markup.goldmark]
[markup.goldmark.extensions]
[markup.goldmark.extensions.passthrough]
enable = true
[markup.goldmark.extensions.passthrough.delimiters]
block = [['\[', '\]'], ['$$', '$$']]
inline = [['\(', '\)']]
Afterwards you can author formulae using the standard syntax:
Examples
Inline math:
Block math:
Chemical equations:
Note: Use the online reference of Supported TeX Functions