Page resources of index pages missing?

Hi,

I have the following structure in my content folder:

content/
  _index.md
  stars/
    _index.md
    images
      1.jpg
  starsandstripes/
    1.jpg

My goal is to create an image gallery for _index.md with the images below “starsandstripes”. I would expect that I can get the images via {{ .Page.Resources }}. But the returned slice is empty!

Is this expected behavior? I would think that the image below starsandstrips should be a page resource for _index.md (it is for regular index.md pages, but I need frontmatter).

It works if I rename the folder starsandstripes to e.g. star-sandstripes, i.e. if it does not start with the name of another folder. Feels like a bug to me, but before I create an issue, I wanted to ask here. Thanks.

It is, and is similar to:
https://github.com/gohugoio/hugo/issues/12465

See:
https://github.com/gohugoio/hugo/issues/13228

Thanks very much for your help!

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