Hackernews inspired theme for Hugo. It's not 1-to-1 clone, but it has a similar feel and look.
Using Git, you can add the theme as a submodule to your Hugo site:
git submodule add https://github.com/hugmouse/hugonews.git themes/hugonews
Add the following to your config.toml
:
theme = "hugonews"
To add more menu items, you need to add them to the menu
section of your config.toml
(hugo.toml
):
[[menus.main]]
name = 'News'
pageRef = '/'
weight = 10
[[menus.main]]
name = 'Posts'
pageRef = '/posts'
weight = 20
[[menus.main]]
name = 'Tags'
pageRef = '/tags'
weight = 30
Let's say we have a menu item called posts
.
To add a description to the page, you need to add the following to your content/posts/_index.md
:
+++
title = 'Posts'
date = 2023-01-01T08:30:00-07:00
draft = false
+++
This is the posts page!