hugo-geekblog/exampleSite/content/posts/features/authors.md

946 B

title date authors tags
Authors 2021-05-23T20:00:00+01:00
john-doe
Documentation
Features

The theme supports multiple authors. The required information for each author need to be stored in a single Hugo data template per author.These files need to be stored in the data/authors/ directory in your projects root.

data/
└── authors
   ├── john-doe.yml
   ├── richard-roe.yml
   └── Special User.yml

The name of the file will be used as the reference later, so if you prefer some kind of naming convention this need to covered by the file names. Example authors file:

name: John Doe
email: john@example.com

With the defined files, you can add as many authors as you want to the front matter of your posts:

---
title: Demo Posts
authors:
  - john-doe
  - Special User
---

My first demo post.