diff --git a/README.md b/README.md index 60a554e54..eba081c96 100644 --- a/README.md +++ b/README.md @@ -2,12 +2,37 @@ Documentation site for [Hugo](https://github.com/gohugoio/hugo), the very fast and flexible static site generator built with love in GoLang. -## Branches +## Contributing -* The `master` branch is the **current Hugo version** and will be auto-deployed to [gohugo.io/](https://gohugo.io/). -* Anything not relevant to the current Hugo version goes into the `dev` branch. -* Changes in [hugo/docs](https://github.com/gohugoio/hugo/tree/master/docs) will, in general, be merged once every release, but can be manually merged/cherry picked if needed. This goes both ways. -* All contributions that is not tightly coupled with code changes, should be made directly to `hugoDocs`. -* But we also merge PRs into [hugo/docs](https://github.com/gohugoio/hugo/tree/master/docs), but preferably changes that is related to the code in the PR itself +We welcome contributions to Hugo of any kind including documentation, suggestions, bug reports, pull requests etc. Also check out our [contribution guide](https://gohugo.io/contribute/documentation/). We would love to hear from you. -To summarize, we have two branches in this repository: `master` (current Hugo) and `dev` (next Hugo). +Note that this repository contains solely the documentation for Hugo. For contributions that aren't documentation-related please refer to the [hugo](https://github.com/gohugoio/hugo) repository. + +*Pull requests shall **only** contain changes to the actual documentation. However, changes on the code base of Hugo **and** the documentation shall be a single, atomic pull request in the [hugo](https://github.com/gohugoio/hugo) repository.* + + +## Build + +To view the documentation site locally, you need to clone this repository with submodules: + +```bash +git clone --recursive https://github.com/gohugoio/hugoDocs.git +``` + +Or if you already have a clone locally: + +```bash +git submodule update --init +``` +Also note that the documentation version for a given version of Hugo can also be found in the `/docs` sub-folder of the [Hugo source repository](https://github.com/gohugoio/hugo). + +Then to view the docs in your browser, run Hugo and open up the link: +```bash +hugo serve +Started building sites ... +. +. +Serving pages from memory +Web Server is available at http://localhost:1313/ (bind address 127.0.0.1) +Press Ctrl+C to stop +``` diff --git a/config.toml b/config.toml index aafb6aa00..08c72176f 100644 --- a/config.toml +++ b/config.toml @@ -16,8 +16,17 @@ pluralizeListTitles = false # We do redirects via Netlify's _redirects file, generated by Hugo (see "outputs" below). disableAliases = true + +# Highlighting config (Pygments) +# It is (currently) not in use, but you can do ```go in a content file if you want to. +pygmentsCodeFences = true + +# See https://help.farbox.com/pygments.html +pygmentsStyle = "friendly" + [outputs] home = [ "HTML", "RSS", "REDIR" ] +section = [ "HTML", "RSS"] [mediaTypes] [mediaTypes."text/netlify"] diff --git a/content/_index.md b/content/_index.md index f23aa99e9..3f9ad64a4 100644 --- a/content/_index.md +++ b/content/_index.md @@ -29,7 +29,7 @@ features: - heading: Custom Outputs image_path: /images/icon-custom-outputs.svg - tagline: HTML not Enough? + tagline: HTML not enough? copy: Hugo allows you to output your content in multiple formats, including JSON or AMP, and makes it easy to create your own. sections: - heading: "100s of Themes" diff --git a/content/about/license.md b/content/about/license.md index 037e62e9b..7575b79c8 100644 --- a/content/about/license.md +++ b/content/about/license.md @@ -148,8 +148,7 @@ _END OF TERMS AND CONDITIONS_ To apply the Apache License to your work, attach the following boilerplate notice, with the fields enclosed by brackets `[]` replaced with your own identifying information. (Don't include the brackets!) The text should be enclosed in the appropriate comment syntax for the file format. We also recommend that a file or class name and description of purpose be included on the same “printed page” as the copyright notice for easier identification within third-party archives. -{{% code file="apache-notice.txt" download="apache-notice.txt" %}} -``` +{{< code file="apache-notice.txt" download="apache-notice.txt" >}} Copyright [yyyy] [name of copyright owner] Licensed under the Apache License, Version 2.0 (the "License"); @@ -163,5 +162,4 @@ distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. -``` -{{% /code %}} +{{< /code >}} diff --git a/content/content-management/archetypes.md b/content/content-management/archetypes.md index d6d30b3f3..9fc58139b 100644 --- a/content/content-management/archetypes.md +++ b/content/content-management/archetypes.md @@ -31,17 +31,15 @@ See above The `hugo new` generator for archetypes assumes your working directory is the content folder at the root of your project. Hugo is able to infer the appropriate archetype by assuming the content type from the content section passed to the CLI command: -```bash +``` hugo new / ``` We can use this pattern to create a new `.md` file in the `posts` section: -{{% code file="archetype-example.sh" %}} -```bash +{{< code file="archetype-example.sh" >}} hugo new posts/my-first-post.md -``` -{{% /code %}} +{{< /code >}} {{% note "Override Content Type in a New File" %}} To override the content type Hugo infers from `[content-section]`, add the `--kind` flag to the end of the `hugo new` command. @@ -50,7 +48,7 @@ To override the content type Hugo infers from `[content-section]`, add the `--ki Running this command in a new site that does not have default or custom archetypes will create the following file: {{% output file="content/posts/my-first-post.md" %}} -```toml +``` +++ date = "2017-02-01T19:20:04-07:00" title = "my first post" @@ -100,14 +98,12 @@ When you create a new Hugo project using `hugo new site`, you'll notice that Hug The following examples are from a site that's using `tags` and `categories` as [taxonomies][]. If we assume that all content files will require these two key-values, we can create a `default.md` archetype that *extends* Hugo's base archetype. In this example, we are including "golang" and "hugo" as tags and "web development" as a category. -{{% code file="archetypes/default.md" %}} -```toml +{{< code file="archetypes/default.md" >}} +++ tags = ["golang", "hugo"] categories = ["web development"] +++ -``` -{{% /code %}} +{{< /code >}} {{% warning "EOL Characters in Text Editors"%}} If you get an `EOF error` when using `hugo new`, add a carriage return after the closing `+++` or `---` for your TOML or YAML front matter, respectively. (See the [troubleshooting article on EOF errors](/troubleshooting/eof-error/) for more information.) @@ -117,16 +113,14 @@ If you get an `EOF error` when using `hugo new`, add a carriage return after the With an `archetypes/default.md` in place, we can use the CLI to create a new post in the `posts` content section: -{{% code file="new-post-from-default.sh" %}} -```bash +{{< code file="new-post-from-default.sh" >}} $ hugo new posts/my-new-post.md -``` -{{% /code %}} +{{< /code >}} Hugo then creates a new markdown file with the following front matter: {{% output file="content/posts/my-new-post.md" %}} -```toml +``` +++ categories = ["web development"] date = "2017-02-01T19:20:04-07:00" @@ -148,30 +142,26 @@ Suppose your site's `posts` section requires more sophisticated front matter tha ### Create a Custom Archetype -{{% code file="archetypes/posts.md"%}} -```toml +{{< code file="archetypes/posts.md">}} +++ description = "" tags = "" categories = "" +++ -``` -{{% /code %}} +{{< /code >}} ### Use a Custom Archetype With an `archetypes/posts.md` in place, you can use the Hugo CLI to create a new post with your preconfigured front matter in the `posts` content section: -{{% code file="new-post-from-custom.sh" %}} -```bash +{{< code file="new-post-from-custom.sh" >}} $ hugo new posts/post-from-custom.md -``` -{{% /code %}} +{{< /code >}} This time, Hugo recognizes our custom `archetypes/posts.md` archetype and uses it instead of `archetypes/default.md`. The generated file will now include the full list of front matter parameters, as well as the base archetype's `title` and `date`: {{% output file="content/posts/post-from-custom-archetype.md" %}} -```toml +``` +++ categories = "" date = 2017-02-13T17:24:43-08:00 @@ -186,11 +176,9 @@ title = "post from custom archetype" As an example of archetypes in practice, the following is the `functions` archetype from the Hugo docs: -{{% code file="archetypes/functions.md" %}} -```yaml +{{< code file="archetypes/functions.md" >}} {{< readfile file="/themes/gohugoioTheme/archetypes/functions.md" >}} -``` -{{% /code %}} +{{< /code >}} {{% note %}} The preceding archetype is kept up to date with every Hugo build by using Hugo's [`readFile` function](/functions/readfile/). For similar examples, see [Local File Templates](/templates/files/). diff --git a/content/content-management/authors.md b/content/content-management/authors.md index 80a783912..0a0d1799d 100644 --- a/content/content-management/authors.md +++ b/content/content-management/authors.md @@ -30,8 +30,7 @@ You can create a profile containing metadata for each author on your website. Th Let's suppose Alice Allison is a blogger. A simple unique identifier would be `alice`. Now, we have to create a file called `alice.toml` in the `data/_authors/` directory. The following example is the standardized template written in TOML: -{{% code file="data/_authors/alice.toml" %}} -```toml +{{< code file="data/_authors/alice.toml" >}} givenName = "Alice" # or firstName as alias familyName = "Allison" # or lastName as alias displayName = "Alice Allison" @@ -50,8 +49,7 @@ weight = 10 [params] random = "whatever you want" -``` -{{% /code %}} +{{< /code >}} All variables are optional but it's advised to fill all important ones (e.g. names and biography) because themes can vary in their usage. @@ -67,7 +65,7 @@ The `params` section can contain arbitrary data much like the same-named section Earlier it was mentioned that content can be associated with an author through their corresponding identifier. In our case, blogger Alice has the identifier `alice`. In the front matter of a content file, you can create a list of identifiers and assign it to the `authors` variable. Here are examples for `alice` using YAML and TOML, respectively. -```yaml +``` --- title: Why Hugo is so Awesome date: 2016-08-22T14:27:502:00 @@ -77,7 +75,7 @@ authors: ["alice"] Nothing to read here. Move along... ``` -```toml +``` +++ title = Why Hugo is so Awesome date = "2016-08-22T14:27:502:00" @@ -116,8 +114,7 @@ This is can be done with the `.Social.URL` function. Its only parameter is the n Most articles feature a small section with information about the author at the end. Let's create one containing the author's name, a thumbnail, a (summarized) biography and links to all social networks: -{{% code file="layouts/partials/author-info.html" download="author-info.html" %}} -```html +{{< code file="layouts/partials/author-info.html" download="author-info.html" >}} {{ with .Author }}

{{ .DisplayName }}

{{ .DisplayName }} @@ -128,8 +125,7 @@ Most articles feature a small section with information about the author at the e {{ end }} {{ end }} -``` -{{% /code %}} +{{< /code >}} ## Who Published What? @@ -137,12 +133,12 @@ That question can be answered with a list of all authors and another list contai In order to let Hugo know that we want to group content based on their author, we have to create a new taxonomy called `author` (the name corresponds to the variable in the front matter). Here is the snippet in a `config.yaml` and `config.toml`, respectively: -```yaml +``` taxonomies: author: authors ``` -```toml +``` [taxonomies] author = "authors" ``` @@ -152,8 +148,7 @@ taxonomies: In the next step we can create a template to list all authors of your website. Later, the list can be accessed at `www.example.com/authors/`. Create a new template in the `layouts/taxonomy/` directory called `authors.term.html`. This template will be exclusively used for this taxonomy. -{{% code file="layouts/taxonomy/author.term.html" download="author.term.html" %}} -```html +{{< code file="layouts/taxonomy/author.term.html" download="author.term.html" >}} -``` -{{% /code %}} +{{< /code >}} `.Data.Terms` contains the identifiers of all authors and we can range over it to create a list with all author names. The `$profile` variable gives us access to the profile of the current author. This allows you to generate a nice info box with a thumbnail, a biography and social media links, like at the [end of a blog post](#linking-social-network-accounts-automatically). @@ -175,15 +169,13 @@ Last but not least, we have to create the second list that contains all publicat The layout for this page can be defined in the template `layouts/taxonomy/author.html`. -{{% code file="layouts/taxonomy/author.html" download="author.html" %}} -```html +{{< code file="layouts/taxonomy/author.html" download="author.html" >}} {{ range .Data.Pages }}

{{ .Title }}

written by {{ .Author.DisplayName }} {{ .Summary }} {{ end }} -``` -{{% /code %}} +{{< /code >}} The example above generates a simple list of all posts written by a single author. Inside the loop you've access to the complete set of [page variables][pagevars]. Therefore, you can add additional information about the current posts like the publishing date or the tags. diff --git a/content/content-management/comments.md b/content/content-management/comments.md index 33387e570..2db449738 100644 --- a/content/content-management/comments.md +++ b/content/content-management/comments.md @@ -29,11 +29,11 @@ Hugo comes with all the code you need to load Disqus into your templates. Before Disqus comments require you set a single value in your [site's configuration file][configuration]. The following show the configuration variable in a `config.toml` and `config.yml`, respectively: -```toml +``` disqusShortname = "yourdiscussshortname" ``` -```yaml +``` disqusShortname: "yourdiscussshortname" ``` diff --git a/content/content-management/cross-references.md b/content/content-management/cross-references.md index 9a2795330..7ee81f3db 100644 --- a/content/content-management/cross-references.md +++ b/content/content-management/cross-references.md @@ -20,7 +20,7 @@ toc: true ## Use `ref` and `relref` -```md +``` {{}} {{}} {{}} @@ -35,14 +35,14 @@ The single parameter to `ref` is a string with a content `documentname` (e.g., ` The `documentname` is the name of a document, including the format extension; this may be just the filename, or the relative path from the `content/` directory. With a document `content/blog/post.md`, either format will produce the same result: -```md +``` {{}} => `/blog/post/` {{}} => `/blog/post/` ``` If you have the same filename used across multiple sections, you should only use the relative path format; otherwise, the behavior will be `undefined`. This is best illustrated with an example `content` directory: -```bash +``` . └── content ├── events @@ -57,16 +57,14 @@ If you have the same filename used across multiple sections, you should only use To be sure to get the correct reference in this case, use the full path: -{{% code file="content/meta/my-article.md" copy="false" %}} -```md +{{< code file="content/meta/my-article.md" copy="false" >}} {{}} => /events/my-birthday/ -``` -{{% /code %}} +{{< /code >}} {{< todo >}}Remove this warning when https://github.com/gohugoio/hugo/issues/3703 is released.{{< /todo >}} A relative document name must *not* begin with a slash (`/`). -```md +``` {{}} => "" ``` @@ -82,14 +80,14 @@ If the page exists in multiple [output formats][], `ref` or `relref` can be used When an `anchor` is provided by itself, the current page’s unique identifier will be appended; when an `anchor` is provided appended to `documentname`, the found page's unique identifier will be appended: -```md +``` {{}} => #anchors:9decaf7 {{}} => /blog/post/#who:badcafe ``` The above examples render as follows for this very page as well as a reference to the "Content" heading in the Hugo docs features pageyoursite -```md +``` {{}} => #who:9decaf7 {{}} => /blog/post/#who:badcafe ``` @@ -98,8 +96,8 @@ More information about document unique identifiers and headings can be found [be ### Examples -* `{{}}` => `http://yoursite.com/blog/post/` -* `{{}}` => `http://yoursite.com/blog/post/#tldr:caffebad` +* `{{}}` => `http://example.com/blog/post/` +* `{{}}` => `http://example.com/blog/post/#tldr:caffebad` * `{{}}` => `/blog/post/` * `{{}}` => `/blog/post/#tldr:caffebad` * `{{}}` => `#tldr:badcaffe` @@ -113,7 +111,7 @@ Ensuring heading uniqueness across the site is accomplished with a unique identi `ref` and `relref` were added so you can make these reference links without having to know the document’s unique identifier. (The links in document tables of contents are automatically up-to-date with this value.) -```md +``` {{}} /content-management/cross-references/#hugo-heading-anchors:77cd9ea530577debf4ce0f28c8dca242 ``` diff --git a/content/content-management/formats.md b/content/content-management/formats.md index ae6276db3..be84e7cf4 100644 --- a/content/content-management/formats.md +++ b/content/content-management/formats.md @@ -41,20 +41,18 @@ Hugo supports [GitHub-styled task lists (i.e., TODO lists)][gfmtasks] for the Bl #### Example Task List Input -{{% code file="content/my-to-do-list.md" %}} -```markdown +{{< code file="content/my-to-do-list.md" >}} - [ ] a task list item - [ ] list syntax required - [ ] incomplete - [x] completed -``` -{{% /code %}} +{{< /code >}} #### Example Task List Output The preceding markdown produces the following HTML in your rendered website: -```html +``` {{ end }} -``` -{{% /code %}} +{{< /code >}} In the above example, you may want `{{.Title}}` to point the `title` field you have added to your `_index.md` file instead. You can access this value using the [`.GetPage` function][getpage]: -{{% code file="layouts/partials/by-page-field.html" %}} -```html +{{< code file="layouts/partials/by-page-field.html" >}} {{ range .Data.Pages.GroupBy "Section" }} @@ -443,13 +404,11 @@ In the above example, you may want `{{.Title}}` to point the `title` field you h {{ end }} {{ end }} -``` -{{% /code %}} +{{< /code >}} ### By Date -{{% code file="layouts/partials/by-page-date.html" %}} -```html +{{< code file="layouts/partials/by-page-date.html" >}} {{ range .Data.Pages.GroupByDate "2006-01" }}

{{ .Key }}

@@ -462,13 +421,11 @@ In the above example, you may want `{{.Title}}` to point the `title` field you h {{ end }} {{ end }} -``` -{{% /code %}} +{{< /code >}} ### By Publish Date -{{% code file="layouts/partials/by-page-publish-date.html" %}} -```html +{{< code file="layouts/partials/by-page-publish-date.html" >}} {{ range .Data.Pages.GroupByPublishDate "2006-01" }}

{{ .Key }}

@@ -481,13 +438,11 @@ In the above example, you may want `{{.Title}}` to point the `title` field you h {{ end }} {{ end }} -``` -{{% /code %}} +{{< /code >}} ### By Page Parameter -{{% code file="layouts/partials/by-page-param.html" %}} -```html +{{< code file="layouts/partials/by-page-param.html" >}} {{ range .Data.Pages.GroupByParam "param_key" }}

{{ .Key }}

@@ -500,15 +455,13 @@ In the above example, you may want `{{.Title}}` to point the `title` field you h {{ end }} {{ end }} -``` -{{% /code %}} +{{< /code >}} ### By Page Parameter in Date Format The following template takes grouping by `date` a step further and uses Golang's layout string. See the [`Format` function][] for more examples of how to use Golang's layout string to format dates in Hugo. -{{% code file="layouts/partials/by-page-param-as-date.html" %}} -```html +{{< code file="layouts/partials/by-page-param-as-date.html" >}} {{ range .Data.Pages.GroupByParamDate "param_key" "2006-01" }}

{{ .Key }}

@@ -521,8 +474,7 @@ The following template takes grouping by `date` a step further and uses Golang's {{ end }} {{ end }} -``` -{{% /code %}} +{{< /code >}} ### Reverse Key Order @@ -532,21 +484,21 @@ While these are logical defaults, they are not always the desired order. There a #### 1. Adding the Reverse Method -```html +``` {{ range (.Data.Pages.GroupBy "Section").Reverse }} ``` -```html +``` {{ range (.Data.Pages.GroupByDate "2006-01").Reverse }} ``` #### 2. Providing the Alternate Direction -```html +``` {{ range .Data.Pages.GroupByDate "2006-01" "asc" }} ``` -```html +``` {{ range .Data.Pages.GroupBy "Section" "desc" }} ``` @@ -560,8 +512,7 @@ Here is the ordering for the example that follows: 2. Groups are listed in ascending order (i.e., the oldest groups first) 3. Pages within each respective group are ordered alphabetically according to the `title`. -{{% code file="layouts/partials/by-group-by-page.html" %}} -```html +{{< code file="layouts/partials/by-group-by-page.html" >}} {{ range .Data.Pages.GroupByDate "2006-01" "asc" }}

{{ .Key }}

{{ end }} -``` -{{% /code %}} +{{< /code >}} ## Filter and Limiting Lists @@ -588,13 +538,11 @@ Sometimes you only want to list a subset of the available content. A common is t 2. `key` *or* `field name` 3. `match value` -{{% code file="layouts/_default/.html" %}} -```html +{{< code file="layouts/_default/.html" >}} {{ range where .Data.Pages "Section" "post" }} {{ .Content }} {{ end }} -``` -{{% /code %}} +{{< /code >}} You can see more examples in the [functions documentation for `where`][wherefunction]. @@ -605,26 +553,22 @@ You can see more examples in the [functions documentation for `where`][wherefunc 1. `array` *or* `slice of maps or structs` 2. `number of elements` -{{% code file="layout/_default/section.html" %}} -```html +{{< code file="layout/_default/section.html" >}} {{ range first 10 .Data.Pages }} {{ .Render "summary" }} {{ end }} -``` -{{% /code %}} +{{< /code >}} ### `first` and `where` Together Using `first` and `where` together can be very powerful: -{{% code file="first-and-where-together.html" %}} -```html +{{< code file="first-and-where-together.html" >}} {{ range first 5 (where .Data.Pages "Section" "post").ByTitle }} {{ .Content }} {{ end }} -``` -{{% /code %}} +{{< /code >}} [base]: /templates/base/ [bepsays]: http://bepsays.com/en/2016/12/19/hugo-018/ @@ -648,4 +592,4 @@ Using `first` and `where` together can be very powerful: [taxvars]: /variables/taxonomy/ [views]: /templates/views/ [wherefunction]: /functions/where/ -[wherekeyword]: https://www.techonthenet.com/sql/where.php \ No newline at end of file +[wherekeyword]: https://www.techonthenet.com/sql/where.php diff --git a/content/templates/lookup-order.md b/content/templates/lookup-order.md index 37d994eed..3f4ff79a0 100644 --- a/content/templates/lookup-order.md +++ b/content/templates/lookup-order.md @@ -52,7 +52,7 @@ The lookup order is best illustrated through examples. The following shows you t 1. The project is using the theme `mytheme` (specified in the project's [configuration][config]). 2. The layouts and content directories for the project are as follows: -```bash +``` . ├── content │ ├── events @@ -88,15 +88,13 @@ Only three of the four markdown files in the above project are subject to the *s ### Example: `my-first-post.md` -{{% code file="content/posts/my-first-post.md" copy="false" %}} -```yaml +{{< code file="content/posts/my-first-post.md" copy="false" >}} --- title: My First Post date: 2017-02-19 description: This is my first post. --- -``` -{{% /code %}} +{{< /code >}} When building your site, Hugo will go through the lookup order until it finds what it needs for `my-first-post.md`: @@ -118,8 +116,7 @@ Notice the term `UNSPECIFIED` rather than `UNDEFINED`. If you don't tell Hugo th ### Example: `my-second-post.md` -{{% code file="content/posts/my-second-post.md" copy="false" %}} -```yaml +{{< code file="content/posts/my-second-post.md" copy="false" >}} --- title: My Second Post date: 2017-02-21 @@ -127,8 +124,7 @@ description: This is my second post. type: review layout: reviewarticle --- -``` -{{% /code %}} +{{< /code >}} Here is the way Hugo traverses the single-page lookup order for `my-second-post.md`: @@ -152,15 +148,13 @@ Notice that the directory for the template for `my-second-post.md` is `review` a ### Example: `my-first-event.md` -{{% code file="content/events/my-first-event.md" copy="false" %}} -```yaml +{{< code file="content/events/my-first-event.md" copy="false" >}} --- title: My First date: 2017-02-21 description: This is an upcoming event.. --- -``` -{{% /code %}} +{{< /code >}} Here is the way Hugo traverses the single-page lookup order for `my-first-event.md`: diff --git a/content/templates/menu-templates.md b/content/templates/menu-templates.md index 791825d16..eb300afe7 100644 --- a/content/templates/menu-templates.md +++ b/content/templates/menu-templates.md @@ -24,8 +24,7 @@ able to build your menu however you want. The following is an example: -{{% code file="layouts/partials/sidebar.html" download="sidebar.html" %}} -```html +{{< code file="layouts/partials/sidebar.html" download="sidebar.html" >}} -``` -{{% /code %}} +{{< /code >}} {{% note "`absLangURL` and `relLangURL`" %}} Use the [`absLangUrl`](/functions/abslangurl) or [`relLangUrl`](/functions/rellangurl) functions if your theme makes use of the [multilingual feature](/content-management/multilingual/). In contrast to `absURL` and `relURL`, these two functions add the correct language prefix to the url. @@ -73,7 +71,7 @@ Use the [`absLangUrl`](/functions/abslangurl) or [`relLangUrl`](/functions/rella To enable this menu, add the following to your site `config`: -```toml +``` SectionPagesMenu = "main" ``` @@ -81,7 +79,7 @@ The menu name can be anything, but take a note of what it is. This will create a menu with all the sections as menu items and all the sections' pages as "shadow-members". The _shadow_ implies that the pages isn't represented by a menu-item themselves, but this enables you to create a top-level menu like this: -```html +```