diff --git a/content/templates/lookup-order.md b/content/templates/lookup-order.md index 88ebe47d0..fd03d5977 100644 --- a/content/templates/lookup-order.md +++ b/content/templates/lookup-order.md @@ -29,7 +29,7 @@ Kind : The page `Kind` (the home page is one). See the example tables below per kind. This also determines if it is a **single page** (i.e. a regular content page. We then look for a template in `_default/single.html` for HTML) or a **list page** (section listings, home page, taxonomy lists, taxonomy terms. We then look for a template in `_default/list.html` for HTML). Output Format -: See [Custom Output Formats](/templates/output-formats). An output format has both a `name` (e.g. 'rss', 'amp', 'html') and a `suffix` (e.g. `xml`, `html`). We prefer matches with both (e.g. `index.amp.html`, but look for less specific templates. +: See [Custom Output Formats](/templates/output-formats). An output format has both a `name` (e.g. `rss`, `amp`, `html`) and a `suffix` (e.g. `xml`, `html`). We prefer matches with both (e.g. `index.amp.html`, but look for less specific templates. Language : We will consider a language code in the template name. If the site language is `fr`, `index.fr.amp.html` will win over `index.amp.html`, but we will `index.amp.html` will be chosen before `index.fr.html`. diff --git a/data/docs.json b/data/docs.json index e87ad11c8..2cd5b5b9c 100644 --- a/data/docs.json +++ b/data/docs.json @@ -247,6 +247,22 @@ "layouts/_default/single.html" ] }, + { + "Example": "Single page in \"posts\" section with theme", + "Kind": "page", + "OutputFormat": "HTML", + "Suffix": "html", + "Template Lookup Order": [ + "layouts/posts/single.html.html", + "demoTheme/layouts/posts/single.html.html", + "layouts/posts/single.html", + "demoTheme/layouts/posts/single.html", + "layouts/_default/single.html.html", + "demoTheme/layouts/_default/single.html.html", + "layouts/_default/single.html", + "demoTheme/layouts/_default/single.html" + ] + }, { "Example": "AMP single page", "Kind": "page", @@ -259,6 +275,22 @@ "layouts/_default/single.html" ] }, + { + "Example": "AMP single page, French language", + "Kind": "page", + "OutputFormat": "AMP", + "Suffix": "html", + "Template Lookup Order": [ + "layouts/posts/single.fr.amp.html", + "layouts/posts/single.amp.html", + "layouts/posts/single.fr.html", + "layouts/posts/single.html", + "layouts/_default/single.fr.amp.html", + "layouts/_default/single.amp.html", + "layouts/_default/single.fr.html", + "layouts/_default/single.html" + ] + }, { "Example": "Home page", "Kind": "home",