Install Bootstrap Module

This article shows how to install the Bootstrap module.

Module
github.com/hugomods/bootstrap
GitHub Stars Used By Used By Used By Used By

Requirements

Some shortcodes like Clearfix require the markup.goldmark.renderer.unsafe to be enabled.

hugo.yaml

1markup:
2  goldmark:
3    renderer:
4      unsafe: true

hugo.toml

1[markup]
2  [markup.goldmark]
3    [markup.goldmark.renderer]
4      unsafe = true

hugo.json

1{
2   "markup": {
3      "goldmark": {
4         "renderer": {
5            "unsafe": true
6         }
7      }
8   }
9}

Installation

hugo.yaml

1module:
2  imports:
3  - path: github.com/hugomods/bootstrap

hugo.toml

1[module]
2  [[module.imports]]
3    path = 'github.com/hugomods/bootstrap'

hugo.json

1{
2   "module": {
3      "imports": [
4         {
5            "path": "github.com/hugomods/bootstrap"
6         }
7      ]
8   }
9}

Additional Styles

Some additional styles are provided to make some shortcodes look nicer.

To use it via Hugo Pipes, you’ll need to import the SCSS files as follows.

1@import 'mods/bootstrap/scss/index';

Notes

This module has two namespaces: bs and bootstrap, both of them are valid, the short one is recommended.