From de37d60720a01bd5044f056ba232c540eb466ab4 Mon Sep 17 00:00:00 2001 From: Manu Date: Thu, 15 Aug 2019 09:36:20 +0800 Subject: [PATCH] Recommend using index.md as parent page for sections Using `index.md` as name for the parent page within a section allows lazy developers to skip defining `permalink`. This is already working and this PR just updates the documentation. --- docs/navigation-structure.md | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/docs/navigation-structure.md b/docs/navigation-structure.md index 98107cf..a4fef75 100644 --- a/docs/navigation-structure.md +++ b/docs/navigation-structure.md @@ -67,7 +67,7 @@ Sometimes you will want to create a page with many children (a section). First, | |-- docs | |-- ui-components -| | |-- ui-components.md (parent page) +| | |-- index.md (parent page) | | |-- buttons.md | | |-- code.md | | |-- labels.md @@ -75,7 +75,7 @@ Sometimes you will want to create a page with many children (a section). First, | | +-- typography.md | | | |-- utilities -| | |-- utilities.md (parent page) +| | |-- index.md (parent page) | | |-- color.md | | |-- layout.md | | |-- responsive-modifiers.md @@ -88,9 +88,8 @@ Sometimes you will want to create a page with many children (a section). First, +-- .. ``` -On the parent pages, add 2 YAML front matter parameters: +On the parent pages, add this YAML front matter parameter: - `has_children: true` (tells us that this is a parent page) -- `permalink:` set this to the site directory that contains the child pages #### Example {: .no_toc } @@ -101,7 +100,6 @@ layout: default title: UI Components nav_order: 2 has_children: true -permalink: /docs/ui-components --- ``` @@ -140,7 +138,6 @@ title: UI Components nav_order: 2 has_children: true has_toc: false -permalink: /docs/ui-components --- ```