测试页面
详细内容
How do I integrate a chat in a website?
This is the detailed content
console.log("Markdown features including the code block are available");
You can use Markdown here including bold and italic text, and inline link 😲😲😲😲😲
选项卡
- Apple
- Orange
- Banana
This is an apple 🍎
This is an orange 🍊
This is a banana 🍌
- Apple
- Orange
- Banana
- Windows
- macOS
- Windows
- macOS
代码块
function HighlightSomeText(highlight) {
if (highlight) {
return '这行被高亮了!';
}
return '这里不会';
}
function HighlightMoreText(highlight) {
if (highlight) {
return '这块被高亮了!';
}
return '这里不会';
}
import React from 'react';
function MyComponent(props) {
if (props.isBar) {
return <div>Bar</div>;
}
return <div>Foo</div>;
}
export default MyComponent;
- JavaScript
- Python
- Java
function helloWorld() {
console.log('Hello, world!');
}
def hello_world():
print("Hello, world!")
class HelloWorld {
public static void main(String args[]) {
System.out.println("Hello, World");
}
}
告示
Some content with Markdown syntax
. Check this api
.
syntax
!Some content with some Markdown syntax
.
Some content with Markdown syntax
. Check this api
.
Some content with Markdown syntax
. Check this api
.
Some content with Markdown syntax
. Check this api
.
Some content with Markdown syntax
. Check this api
.
Parent content
Child content
Deep child content
- Apple
- Orange
- Banana
Doc Markdown front matter
Markdown documents can use the following Markdown front matter metadata fields, enclosed by a line ---
on either side.
接受的字段:
参数 | 类型 | 默认值 | 描述 |
---|---|---|---|
id | string | 文件路径(包括文件夹,不含扩展名) | 文档的唯一 ID。 |
title | string | Markdown title or id | 你的文档使用的文本标题。 用于页面元数据和多个地方的备用值(侧边栏、下篇/上篇按钮……)。 如果 Markdown 内容没有标题,它会被自动添加到你的文档顶部。 |
pagination_label | string | sidebar_label or title | 这篇文档在上一篇/下一篇按钮中显示的文本 |
sidebar_label | string | title | 这篇文档在侧边栏中显示的文本 |
sidebar_position | number | 默认排序 | Controls the position of a doc inside the generated sidebar slice when using autogenerated sidebar items. See also Autogenerated sidebar metadata. |
sidebar_class_name | string | undefined | 在使用自动生成侧边栏时,给相应的侧边栏标签一个特殊类名。 |
sidebar_custom_props | object | undefined | Assign custom props to the sidebar item referencing this doc |
displayed_sidebar | string | undefined | Force the display of a given sidebar when browsing the current document. Read the multiple sidebars guide for details. |
hide_title | boolean | false | 是否隐藏文档顶部显示的标题。 此选项只会隐藏前言中定义的标题,对于 Markdown 文档顶部的标题没有任何影响。 |
hide_table_of_contents | boolean | false | 是否隐藏右侧的文档目录。 |
toc_min_heading_level | number | 2 | 目录中显示的最小标题层级。 必须介于 2 到 6 之间,并且小于等于最大值。 |
toc_max_heading_level | number | 3 | 目录中显示的最大标题层级。 必须介于 2 和 6。 |
pagination_next | `string | null` | 侧边栏的下一个文档 |
pagination_prev | `string | null` | 侧边栏的上一个文档 |
parse_number_prefixes | boolean | numberPrefixParser plugin option | 是否禁用本文档的数字前缀解析。 See also Using number prefixes. |
custom_edit_url | `string | null` | Computed using the editUrl plugin option |
keywords | string[] | undefined | 用于搜索引擎优化的文档关键词元标签。 |
description | string | Markdown 正文的第一行 | The description of your document, which will become the and in ``, used by search engines. |
image | string | undefined | Cover or thumbnail image that will be used as the in the , enhancing link previews on social media and messaging platforms. |
slug | string | 文件路径 | Allows to customize the document URL (// ). Support multiple patterns: slug: my-doc , slug: /my/path/myDoc , slug: / . |
tags | Tag[] | undefined | A list of strings or objects of two string fields label and permalink to tag to your docs. Strings can be a reference to keys of a tags file (usually tags.yml ) |
draft | boolean | false | Draft documents will only be available during development. |
unlisted | boolean | false | Unlisted documents will be available in both development and production. They will be "hidden" in production, not indexed, excluded from sitemaps, and can only be accessed by users having a direct link. |
last_update | FrontMatterLastUpdate | undefined | Allows overriding the last update author/date. Date can be any parsable date string. |
Blog Markdown front matter
Markdown documents can use the following Markdown [front matter](📦 plugin-content-blog | Docusaurus) metadata fields, enclosed by a line ---
on either side.
Accepted fields:
Name | Type | Default | Description |
---|---|---|---|
authors | Authors | undefined | List of blog post authors (or unique author). Read the authors guide for more explanations. Prefer authors over the author_* front matter fields, even for single author blog posts. |
author | string | undefined | ⚠️ Prefer using authors . The blog post author's name. |
author_url | string | undefined | ⚠️ Prefer using authors . The URL that the author's name will be linked to. This could be a GitHub, X, Facebook profile URL, etc. |
author_image_url | string | undefined | ⚠️ Prefer using authors . The URL to the author's thumbnail image. |
author_title | string | undefined | ⚠️ Prefer using authors . A description of the author. |
title | string | Markdown title | The blog post title. |
date | string | File name or file creation time | The blog post creation date. If not specified, this can be extracted from the file or folder name, e.g, 2021-04-15-blog-post.mdx , 2021-04-15-blog-post/index.mdx , 2021/04/15/blog-post.mdx . Otherwise, it is the Markdown file creation time. |
tags | Tag[] | undefined | A list of strings or objects of two string fields label and permalink to tag to your post. Strings can be a reference to keys of a tags file (usually tags.yml ) |
draft | boolean | false | Draft blog posts will only be available during development. |
unlisted | boolean | false | Unlisted blog posts will be available in both development and production. They will be "hidden" in production, not indexed, excluded from sitemaps, and can only be accessed by users having a direct link. |
hide_table_of_contents | boolean | false | Whether to hide the table of contents to the right. |
toc_min_heading_level | number | 2 | The minimum heading level shown in the table of contents. Must be between 2 and 6 and lower or equal to the max value. |
toc_max_heading_level | number | 3 | The max heading level shown in the table of contents. Must be between 2 and 6. |
keywords | string[] | undefined | Keywords meta tag, which will become the <meta name="keywords" content="keyword1,keyword2,..."/> in <head> , used by search engines. |
description | string | The first line of Markdown content | The description of your document, which will become the <meta name="description" content="..."/> and <meta property="og:description" content="..."/> in <head> , used by search engines. |
image | string | undefined | Cover or thumbnail image that will be used as the <meta property="og:image" content="..."/> in the <head> , enhancing link previews on social media and messaging platforms. |
slug | string | File path | Allows to customize the blog post URL (/<routeBasePath>/<slug> ). Support multiple patterns: slug: my-blog-post , slug: /my/path/to/blog/post , slug: / . |
last_update | FrontMatterLastUpdate | undefined | Allows overriding the last update author/date. Date can be any parsable date string. |