Hi there,
I’m trying to get modular subpages in an another page, but it’s not working, the array I get is empty…
Here’s the frontmatter of the page where I want to get the modular subpages :
title: 'page title'
template: custom
content:
items:
'@page.modular': '/modular-page'
the twig in the template :
{% for p in page.collection %}
<h2>{{ p.title }}</h2>
{% endfor %}
and the modular.md frontmatter :
title: Modular Page
onpage_menu: true
body_classes: ""
content:
items: '@self.modular'
order:
by: default
dir: asc
custom:
- _modular-section-1
- _modular-section-2
- _modular-section-3
- _modular-section-4
Am I missing something ?