HUGO
News Docs Themes Community GitHub

Comic

Hugo Comic Theme

License
MIT
GitHub Stars
0
Last Updated
2024-05-22

hugo-theme-comic: Hugo Comic Theme

Don’t worry, this theme does not change your Hugo site’s default font to Comic Sans. 😌

Instead, it renders comic strips that are organized by date:

alt text{width=532px}

Features

  • Home view with a jump list to each year and the most recent strips
  • Yearly view with a jump list to each month
  • Monthly view
  • Menu for fast year selection

Demo

Hugo Comic Theme Demo

Source code for the demo site

The comic strips for the demo site are from: https://xkcd.com/

Installation

Download the theme:

mkdir themes
cd themes
git clone https://gitlab.com/mrubli/hugo-theme-comic

Update your Hugo site configuration file (e.g. hugo.yaml) to include this line:

theme: hugo-theme-comic

Directory structure

The comic strip files are expected to live in the content/ directory, in a yyyy/mm/yyyy-mm-dd.ext structure. Furthermore, all directories must contain an empty _index.md file, so that Hugo processes the directory.

For example:

content/
└── 2024
    β”œβ”€β”€ 01
    β”‚Β Β  β”œβ”€β”€ 2024-01-01.jpg
    β”‚Β Β  β”œβ”€β”€ 2024-01-02.jpg
    β”‚Β Β  β”œβ”€β”€ 2024-01-03.jpg
    β”‚Β Β  β”œβ”€β”€ …
    β”‚Β Β  β”œβ”€β”€ 2024-01-31.jpg
    β”‚Β Β  └── _index.md
    β”œβ”€β”€ 02
    β”‚Β Β  β”œβ”€β”€ 2024-02-01.jpg
    β”‚Β Β  β”œβ”€β”€ …
    β”‚Β Β  └── _index.md

The following command can be used to create _index.md files in all relevant directories.

find content/???? -type d -exec touch {}/_index.md \;
Β