@tim I have just installed skeleton 'One-Page site' (based on Quark) to test custom ordering.
TL;DR: Custom ordering works fine in demo setup mimicking your config.
'One-Page site' has the following modular page:
title: One Page Demo Site
menu: Home
onpage_menu: true
body_classes: title-h1h2 header-dark header-transparent
content:
items: @self.modular
And folder structure:
/01.home
/01._hero # menu: Top
/02._highlights # menu: Highlights
/03._callout # menu: Easy Content
/04._features # menu: Features
modular.md
And I replaced template 'modular.html.twig with:
{% extends 'partials/base.html.twig' %}
{% block content %}
{% for module in page.collection() %}
{{module.menu}}
{# {{ module.content }} #}
{% endfor %}
{% endblock %}
Running the above config shows the default ordering by number: Top / Highlights / Easy Content / Features
When I add custom ordering (reversing default order):
content:
items: @self.modular
order:
by: default
custom:
- _features # Features
- _callout # Easy Content
- _highlights # Highlights
- _hero # Top
Now the list is reversed as expected: Features / Easy Content / Highlights / Top
Two notes from the docs on Ordering Options:
- Please note that if a page is not specified in the custom ordering list, then Grav falls back on the
content.order.by for the unspecified pages.
- If a page has a custom slug, you must use that slug in the
content.order.custom list.
Questions:
- How does your folder structure look like?
- How does the frontmatter of a child-page look like?
- What theme are you using?
- Have you tried a default theme like Quark?
- If Quark shows no change, have your tried a fresh install of Grav?
NB. For legibility of code snippets you might want to use correct indentation and embed code inside ``` (triple back-ticks, or accent grave).