Modular pages and non children

Still new to all this, so please bear with me here.

I could be way off in my understanding of modular pages, but is it possible to have a modular page made up of pages from other parents.

In my example I’m making a genealogy site for me family and ideally I would like to have a parent page containing all the individual people, and then another parent page of the families. Each one would be constructed from the appropriate people pages plus maybe a bit more text.

Is this possible? Or can a modular page only be made up of direct children?


Hopefully this image illustrates what I mean a bit better.

This is possible with a little workaround.

You would have to add taxonomy to each of your modular pages that you wish to identify, then you would have to use a @taxonomy content collection rather than a @self.modular in your top level modular page.

@self.modular always looks for modular pages under the current page, however, @taxonomy can look anywhere, and will find any pages that match the provided taxonomy query.

Below are a few little examples of how you might structure this taxonomy query.

@taxonomy.category: blog
@taxonomy.category: [ blog, featured ]
@taxonomy: { category: [ blog, featured ], level: 1 }

That should be able to work fine, I think. Thanks a lot!

For reference I ended up going with the PageInject plugin, seemed to be the easiest and cleanest solution.