diff --git a/website/docs/blog.mdx b/website/docs/blog.mdx index 96dee72d9d..a028526023 100644 --- a/website/docs/blog.mdx +++ b/website/docs/blog.mdx @@ -181,7 +181,8 @@ Blog post authors can be declared directly inside the FrontMatter: values={[ {label: 'Single author', value: 'single'}, {label: 'Multiple authors', value: 'multiple'}, - ]}> + ]} + groupId="author-frontmatter"> ```yml title="my-blog-post.md" @@ -225,6 +226,7 @@ This option works best to get started, or for casual, irregular authors. Prefer usage of the `authors` FrontMatter, but the legacy `author_*` FrontMatter remains supported: + ```yml title="my-blog-post.md" --- author: Joel Marcey @@ -232,8 +234,8 @@ author_title: Co-creator of Docusaurus 1 author_url: https://github.com/JoelMarcey author_image_url: https://github.com/JoelMarcey.png --- - ``` + ::: @@ -271,7 +273,8 @@ In blog posts FrontMatter, you can reference the authors declared in the global values={[ {label: 'Single author', value: 'single'}, {label: 'Multiple authors', value: 'multiple'}, - ]}> + ]} + groupId="author-frontmatter"> ```yml title="my-blog-post.md" @@ -302,6 +305,7 @@ The `authors` system is very flexible and can suit more advanced use-case: You can use global authors most of the time, and still use inline authors: + ```yml title="my-blog-post.md" --- authors: @@ -312,16 +316,17 @@ authors: url: https://github.com/inlineAuthor image_url: https://github.com/inlineAuthor --- - ``` +
Local override of global authors -You can customize the global author's data on per-blog-post basis +You can customize the global author's data on per-blog-post basis: + ```yml title="my-blog-post.md" --- authors: @@ -330,8 +335,8 @@ authors: - key: slorber name: Sébastien Lorber's new name --- - ``` +
diff --git a/website/docs/guides/docs/docs-create-doc.mdx b/website/docs/guides/docs/docs-create-doc.mdx index 4abbec3db2..ab4d584d15 100644 --- a/website/docs/guides/docs/docs-create-doc.mdx +++ b/website/docs/guides/docs/docs-create-doc.mdx @@ -83,3 +83,19 @@ With {#custom-id} syntax you can set your own header id. ``` + +## Doc tags {#doc-tags} + +Optionally, you can add tags to your doc pages, which introduces another dimension of categorization in addition to the [docs sidebar](./sidebar.md). Tags are passed in the front matter as a list of labels: + + +```yml "your-doc-page.md" +--- +id: doc-with-tags +title: A doc with tags +tags: + - Demo + - Getting started +--- +``` +