Page with 2 categories: Art, Sport. List overview articles, content folder setup

Hello,
I am doing some tutorials and I am still asking myself how to setup the content folder.
First the way I set up new project:

  • hugo new site name
  • hugo new theme mytheme
  • config.toml -> theme = “mytheme”

Setup of the page:
├──main site
├───Art, list with all art articles (index page)
_____├────Article 1
_____└────Article 2
└───Sport, list with all sport articles (index page)
_____├────Article 1
_____└────Article 2

How would the content folder look like?
In content folder, for each category a folder has to be created: Art, Sport. But where do the index page goes to?

Thank you.

“index page” as in start page? thats content/_index.md. You can add front matter like on any other page. The only thing you need to check is that your theme needs a “_defaults/index.html” where you define how that page is displayed so it does not show a list of recent posts.

The index page is working, content/Games/ contains: _index.md, gta5.md, skyrim.md but if I klick on the index page on Gta5, I get themes/mytheme/layouts/_default/single.html instead of the article, which looks like this:

title: “Grand Theft Auto 5”
date: 2018-10-19T16:10:36-04:00
draft: false
tags: [ “third person”, “shooter” ]

some text here

It’s time to link to your repository and a test installation :wink: I don’t understand what exactly is the issue… It might just be a missing slash somewhere in an URL.

The issue was, that the .md (the article) files didn’t load, instead the _default/single.html was loaded.
Because I have games & news in content, I created games & news dir in themes/mytheme/archetypes.
Then I created single.html in both directories and added {{ .Content }}
Thank you anyway pkollitsch.