Skip to main content


This documentation is work in progress. Please check back later.

A GoHugo theme component with helper functions for other projects.

Some things you need to know

These are notes about conventions in this You might want to make yourself acquainted with them if this is your first visit.

The following documentation will refer to all configuration parameters in TOML format and with the assumption of a configuration file for your project at /config.toml. There are various formats of configurations (TOML/YAML/JSON) and multiple locations your configuration can reside (config file or config directory). Note that in the case of a config directory the section headers of all samples need to have the respective section title removed. So [params.dnb.something] will become [dnb.something] if the configuration is done in the file /config/$CONFIGNAME/params.toml.


First enable modules in your own repository if you did not already have done so:

1hugo mod init

Then add this module to your required modules in config.toml.

3    disable = false
4    ignoreConfig = false
5    ignoreImports = false
6    path = ''
2  imports:
3  - disable: false
4    ignoreConfig: false
5    ignoreImports: false
6    path:
 2   "module": {
 3      "imports": [
 4         {
 5            "disable": false,
 6            "ignoreConfig": false,
 7            "ignoreImports": false,
 8            "path": ""
 9         }
10      ]
11   }

The next time you run hugo it will download the latest version of the module.


1# update this module
2hugo mod get -u
3# update to a specific version
4hugo mod get -u[email protected]
5# update all modules recursively over the whole project
6hugo mod get -u ./...

Working principle

While being named functions this component adds merely partials that return values. In these partials calculations are done, so we might un-nerdily call them functions. The reason for this is that Hugo does not allow for functions to be added to a theme component. So we are using partials instead.

Back to top
Back Forward