Can you have both and in the same directory?

I ran hugo server and it ran the server, but when I clicked on the post itself, it didn’t navigate to the post.

You can’t. Both give the containing folder an instruction.

  • instructs hugo to create a single page. It uses the single.html layout
  • instructions hugo to creates a section. It uses the list.html layout

If you put both, then hugo won’t know which one to choose.

For more on that see here: Page bundles | Hugo

tldr for a given directory you should have one or the other, not both


This topic was automatically closed 2 days after the last reply. New replies are no longer allowed.