From 779c54ef47e6dc0c87b3cee06c0980af525d3bee Mon Sep 17 00:00:00 2001 From: squidfunk Date: Thu, 20 Feb 2025 08:34:42 +0700 Subject: [PATCH] Documentation --- docs/setup/setting-up-navigation.md | 38 +++++++++++++++++------------ 1 file changed, 22 insertions(+), 16 deletions(-) diff --git a/docs/setup/setting-up-navigation.md b/docs/setup/setting-up-navigation.md index b36aa9ec2..c9a61bab0 100644 --- a/docs/setup/setting-up-navigation.md +++ b/docs/setup/setting-up-navigation.md @@ -137,12 +137,13 @@ instant previews on a per-page or per-section level for your documentation: ``` yaml markdown_extensions: - material.extensions.preview: - targets: - include: - - changelog/index.md - - customization.md - - insiders/changelog/* - - setup/extensions/* + configurations: + - targets: + include: + - changelog/index.md + - customization.md + - insiders/changelog/* + - setup/extensions/* ``` The above configuration is what we use for our documentation. We've enabled @@ -154,16 +155,17 @@ as well as for all Markdown extensions that we support. ``` yaml markdown_extensions: - material.extensions.preview: - sources: # (1)! - include: - - ... - exclude: - - ... - targets: # (2)! - include: - - ... - exclude: - - ... + configurations: + - sources: # (1)! + include: + - ... + exclude: + - ... + targets: # (2)! + include: + - ... + exclude: + - ... ``` 1. Sources specify the pages _on_ which instant previews should be enabled. @@ -172,6 +174,10 @@ as well as for all Markdown extensions that we support. evaluated on top of inclusion, so if a page is matched by both, it will be excluded. + Note that you can define multiple items under the `configurations` + setting, which allows to precisely control where instant previews are + shown. + 2. Targets specify the pages _to_ which instant previews should be enabled. This is the recommended way to enable instant previews. ---