mirror of
https://github.com/facebook/docusaurus.git
synced 2025-08-03 16:59:06 +02:00
parent
a1ef13941f
commit
6f9d2c4605
84 changed files with 504 additions and 328 deletions
|
@ -84,6 +84,7 @@
|
|||
<h2><a class="anchor" aria-hidden="true" id="目录结构"></a><a href="#目录结构" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>目录结构</h2>
|
||||
<p>正如<a href="/docs/zh-CN/next/installation">安装 Docusaurus</a>后所示, 初始化脚本创建了一个类似于以下内容的目录结构:</p>
|
||||
<pre><code class="hljs css language-bash">root-directory
|
||||
├── .gitignore
|
||||
├── docs
|
||||
│ ├── doc1.md
|
||||
│ ├── doc2.md
|
||||
|
@ -114,13 +115,15 @@
|
|||
</ul>
|
||||
<h3><a class="anchor" aria-hidden="true" id="关键文件"></a><a href="#关键文件" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>关键文件</h3>
|
||||
<ul>
|
||||
<li><strong>页脚</strong>:<code>website/core/Footer.js</code> 文件是一个 React 组件,用于生成 Docusaurus 站点的页脚,它可以由用户定制。</li>
|
||||
<li><strong>配置文件</strong>:<code>website/siteConfig.js</code> 文件是 Docusaurus 的主配置文件。</li>
|
||||
<li><strong>Footer</strong>: The <code>website/core/Footer.js</code> file is a React component that acts as the footer for the site generated by Docusaurus and should be customized by the user.</li>
|
||||
<li><strong>Configuration file</strong>: The <code>website/siteConfig.js</code> file is the main configuration file used by Docusaurus.</li>
|
||||
<li><strong>Sidebars</strong>: The <code>sidebars.json</code> file contains the structure and order of the documentation files.</li>
|
||||
<li><strong>.gitignore</strong>: The <code>.gitignore</code> file lists the necessary ignore files for the generated site so that they do not get added to the git repo.</li>
|
||||
</ul>
|
||||
<h2><a class="anchor" aria-hidden="true" id="准备说明"></a><a href="#准备说明" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>准备说明</h2>
|
||||
<p>You will need to keep the <code>website/siteConfig.js</code> and <code>website/core/Footer.js</code> files but may edit them as you wish. The value of the <code>customDocsPath</code> key in <code>website/siteConfig.js</code> can be modified if you wish to use a different directory name or path. The <code>website</code> directory can also be renamed to anything you want it to be.</p>
|
||||
<p>However, you should keep the <code>website/pages</code> and <code>website/static</code> directories. You may change the content inside them as you wish. At the bare minimum, you should have an <code>en/index.js</code> or <code>en/index.html</code> file inside <code>website/pages</code> and an image to use as your header icon inside <code>website/static</code>.</p>
|
||||
<p>If your directory does not yet have a <code>.gitignore</code>, we generate it with the necessary ignored files listed. As a general rule, you should ignore all <code>node_modules</code>, build files, system files (<code>.DS_Store</code>), logs, etc. <a href="https://github.com/github/gitignore/blob/master/Node.gitignore">Here</a> is a more comprehensive list of what is normally ignored for Node.js projects.</p>
|
||||
</span></div></article></div><div class="docs-prevnext"><a class="docs-prev button" href="/docs/zh-CN/next/installation"><span class="arrow-prev">← </span><span>安装</span></a><a class="docs-next button" href="/docs/zh-CN/next/site-creation"><span>创建你的站点</span><span class="arrow-next"> →</span></a></div></div></div><nav class="onPageNav"><ul class="toc-headings"><li><a href="#目录结构">目录结构</a><ul class="toc-headings"><li><a href="#目录介绍">目录介绍</a></li><li><a href="#关键文件">关键文件</a></li></ul></li><li><a href="#准备说明">准备说明</a></li></ul></nav></div><footer class="nav-footer" id="footer"><section class="sitemap"><a href="/" class="nav-home"><img src="/img/docusaurus_monochrome.svg" alt="Docusaurus" width="66" height="58"/></a><div class="footerSection"><h5>Docs</h5><a href="
|
||||
/docs/zh-CN/installation">Getting Started</a><a href="
|
||||
/docs/zh-CN/versioning">Versioning</a><a href="
|
||||
|
|
|
@ -84,6 +84,7 @@
|
|||
<h2><a class="anchor" aria-hidden="true" id="目录结构"></a><a href="#目录结构" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>目录结构</h2>
|
||||
<p>正如<a href="/docs/zh-CN/next/installation">安装 Docusaurus</a>后所示, 初始化脚本创建了一个类似于以下内容的目录结构:</p>
|
||||
<pre><code class="hljs css language-bash">root-directory
|
||||
├── .gitignore
|
||||
├── docs
|
||||
│ ├── doc1.md
|
||||
│ ├── doc2.md
|
||||
|
@ -114,13 +115,15 @@
|
|||
</ul>
|
||||
<h3><a class="anchor" aria-hidden="true" id="关键文件"></a><a href="#关键文件" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>关键文件</h3>
|
||||
<ul>
|
||||
<li><strong>页脚</strong>:<code>website/core/Footer.js</code> 文件是一个 React 组件,用于生成 Docusaurus 站点的页脚,它可以由用户定制。</li>
|
||||
<li><strong>配置文件</strong>:<code>website/siteConfig.js</code> 文件是 Docusaurus 的主配置文件。</li>
|
||||
<li><strong>Footer</strong>: The <code>website/core/Footer.js</code> file is a React component that acts as the footer for the site generated by Docusaurus and should be customized by the user.</li>
|
||||
<li><strong>Configuration file</strong>: The <code>website/siteConfig.js</code> file is the main configuration file used by Docusaurus.</li>
|
||||
<li><strong>Sidebars</strong>: The <code>sidebars.json</code> file contains the structure and order of the documentation files.</li>
|
||||
<li><strong>.gitignore</strong>: The <code>.gitignore</code> file lists the necessary ignore files for the generated site so that they do not get added to the git repo.</li>
|
||||
</ul>
|
||||
<h2><a class="anchor" aria-hidden="true" id="准备说明"></a><a href="#准备说明" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>准备说明</h2>
|
||||
<p>You will need to keep the <code>website/siteConfig.js</code> and <code>website/core/Footer.js</code> files but may edit them as you wish. The value of the <code>customDocsPath</code> key in <code>website/siteConfig.js</code> can be modified if you wish to use a different directory name or path. The <code>website</code> directory can also be renamed to anything you want it to be.</p>
|
||||
<p>However, you should keep the <code>website/pages</code> and <code>website/static</code> directories. You may change the content inside them as you wish. At the bare minimum, you should have an <code>en/index.js</code> or <code>en/index.html</code> file inside <code>website/pages</code> and an image to use as your header icon inside <code>website/static</code>.</p>
|
||||
<p>If your directory does not yet have a <code>.gitignore</code>, we generate it with the necessary ignored files listed. As a general rule, you should ignore all <code>node_modules</code>, build files, system files (<code>.DS_Store</code>), logs, etc. <a href="https://github.com/github/gitignore/blob/master/Node.gitignore">Here</a> is a more comprehensive list of what is normally ignored for Node.js projects.</p>
|
||||
</span></div></article></div><div class="docs-prevnext"><a class="docs-prev button" href="/docs/zh-CN/next/installation"><span class="arrow-prev">← </span><span>安装</span></a><a class="docs-next button" href="/docs/zh-CN/next/site-creation"><span>创建你的站点</span><span class="arrow-next"> →</span></a></div></div></div><nav class="onPageNav"><ul class="toc-headings"><li><a href="#目录结构">目录结构</a><ul class="toc-headings"><li><a href="#目录介绍">目录介绍</a></li><li><a href="#关键文件">关键文件</a></li></ul></li><li><a href="#准备说明">准备说明</a></li></ul></nav></div><footer class="nav-footer" id="footer"><section class="sitemap"><a href="/" class="nav-home"><img src="/img/docusaurus_monochrome.svg" alt="Docusaurus" width="66" height="58"/></a><div class="footerSection"><h5>Docs</h5><a href="
|
||||
/docs/zh-CN/installation">Getting Started</a><a href="
|
||||
/docs/zh-CN/versioning">Versioning</a><a href="
|
||||
|
|
|
@ -82,9 +82,9 @@
|
|||
});
|
||||
</script></nav></div><div class="container mainContainer"><div class="wrapper"><div class="post"><header class="postHeader"><a class="edit-page-link button" href="https://crowdin.com/project/docusaurus/zh-CN" target="_blank" rel="noreferrer noopener">Translate</a><h1 class="postHeaderTitle">Create Pages</h1></header><article><div><span><p>In this section, we will learn about creating two types of pages in Docusaurus: a regular page and a documentation page.</p>
|
||||
<p><img alt="Docusaurus MacBook" src="/img/undraw_docusaurus_tree.svg" class="docImage" /></p>
|
||||
<h2><a class="anchor" aria-hidden="true" id="creating-a-regular-page"></a><a href="#creating-a-regular-page" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Creating a Regular Page</h2>
|
||||
<h2><a class="anchor" aria-hidden="true" id="create-a-regular-page"></a><a href="#create-a-regular-page" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Create a Regular Page</h2>
|
||||
<ol>
|
||||
<li><p>Go into the <code>pages/en</code> directory and create a file called <code>hello-world.js</code> with the following contents:</p>
|
||||
<li><p>In the <code>website/pages/en</code> directory of your repository, save a text file called <code>hello-world.js</code> with the following contents:</p>
|
||||
<p>const React = require('react');</p>
|
||||
<p>const CompLibrary = require('../../core/CompLibrary.js');</p>
|
||||
<p>const Container = CompLibrary.Container;
|
||||
|
@ -101,9 +101,12 @@ return (
|
|||
}</p>
|
||||
<p>module.exports = HelloWorld;</p></li>
|
||||
</ol>
|
||||
<blockquote>
|
||||
<p>Use any text editor to make the file, such as <a href="https://code.visualstudio.com/download">Microsoft Visual Studio Code</a> or <a href="https://www.activestate.com/komodo-edit">Komodo Edit</a>.</p>
|
||||
</blockquote>
|
||||
<ol start="2">
|
||||
<li>Go to <a href="http://localhost:3000/hello-world">http://localhost:3000/hello-world</a> and you should be able to see the new page.</li>
|
||||
<li>Change the text within the <code><p>...</p></code> to "I can write JSX here!". The browser should refresh automatically to reflect the changes.</li>
|
||||
<li>Change the text within the <code><p>...</p></code> to "I can write JSX here!" and save the file again. The browser should refresh automatically to reflect the change.</li>
|
||||
</ol>
|
||||
<pre><code class="hljs css language-diff"><span class="hljs-deletion">- <p>This is my first page!</p></span>
|
||||
<span class="hljs-addition">+ <p>I can write JSX here!</p></span>
|
||||
|
@ -154,7 +157,7 @@ id sem consectetuer libero luctus adipiscing.</p>
|
|||
</ol>
|
||||
<p>You've created your first documentation page on Docusaurus!</p>
|
||||
<p>Learn more about creating docs pages <a href="navigation">here</a>.</p>
|
||||
</span></div></article></div><div class="docs-prevnext"><a class="docs-prev button" href="/docs/zh-CN/next/tutorial-create-new-site"><span class="arrow-prev">← </span><span>Create a New Site</span></a><a class="docs-next button" href="/docs/zh-CN/next/tutorial-publish-site"><span>Publish the Site</span><span class="arrow-next"> →</span></a></div></div></div><nav class="onPageNav"><ul class="toc-headings"><li><a href="#creating-a-regular-page">Creating a Regular Page</a></li><li><a href="#create-a-documentation-page">Create a Documentation Page</a></li><li><a href="#markdown-syntax">Markdown Syntax</a></li></ul></nav></div><footer class="nav-footer" id="footer"><section class="sitemap"><a href="/" class="nav-home"><img src="/img/docusaurus_monochrome.svg" alt="Docusaurus" width="66" height="58"/></a><div class="footerSection"><h5>Docs</h5><a href="
|
||||
</span></div></article></div><div class="docs-prevnext"><a class="docs-prev button" href="/docs/zh-CN/next/tutorial-create-new-site"><span class="arrow-prev">← </span><span>Create a New Site</span></a><a class="docs-next button" href="/docs/zh-CN/next/tutorial-publish-site"><span>Publish the Site</span><span class="arrow-next"> →</span></a></div></div></div><nav class="onPageNav"><ul class="toc-headings"><li><a href="#create-a-regular-page">Create a Regular Page</a></li><li><a href="#create-a-documentation-page">Create a Documentation Page</a></li><li><a href="#markdown-syntax">Markdown Syntax</a></li></ul></nav></div><footer class="nav-footer" id="footer"><section class="sitemap"><a href="/" class="nav-home"><img src="/img/docusaurus_monochrome.svg" alt="Docusaurus" width="66" height="58"/></a><div class="footerSection"><h5>Docs</h5><a href="
|
||||
/docs/zh-CN/installation">Getting Started</a><a href="
|
||||
/docs/zh-CN/versioning">Versioning</a><a href="
|
||||
/docs/zh-CN/translation">Localization</a><a href="
|
||||
|
|
|
@ -82,9 +82,9 @@
|
|||
});
|
||||
</script></nav></div><div class="container mainContainer"><div class="wrapper"><div class="post"><header class="postHeader"><a class="edit-page-link button" href="https://crowdin.com/project/docusaurus/zh-CN" target="_blank" rel="noreferrer noopener">Translate</a><h1 class="postHeaderTitle">Create Pages</h1></header><article><div><span><p>In this section, we will learn about creating two types of pages in Docusaurus: a regular page and a documentation page.</p>
|
||||
<p><img alt="Docusaurus MacBook" src="/img/undraw_docusaurus_tree.svg" class="docImage" /></p>
|
||||
<h2><a class="anchor" aria-hidden="true" id="creating-a-regular-page"></a><a href="#creating-a-regular-page" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Creating a Regular Page</h2>
|
||||
<h2><a class="anchor" aria-hidden="true" id="create-a-regular-page"></a><a href="#create-a-regular-page" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Create a Regular Page</h2>
|
||||
<ol>
|
||||
<li><p>Go into the <code>pages/en</code> directory and create a file called <code>hello-world.js</code> with the following contents:</p>
|
||||
<li><p>In the <code>website/pages/en</code> directory of your repository, save a text file called <code>hello-world.js</code> with the following contents:</p>
|
||||
<p>const React = require('react');</p>
|
||||
<p>const CompLibrary = require('../../core/CompLibrary.js');</p>
|
||||
<p>const Container = CompLibrary.Container;
|
||||
|
@ -101,9 +101,12 @@ return (
|
|||
}</p>
|
||||
<p>module.exports = HelloWorld;</p></li>
|
||||
</ol>
|
||||
<blockquote>
|
||||
<p>Use any text editor to make the file, such as <a href="https://code.visualstudio.com/download">Microsoft Visual Studio Code</a> or <a href="https://www.activestate.com/komodo-edit">Komodo Edit</a>.</p>
|
||||
</blockquote>
|
||||
<ol start="2">
|
||||
<li>Go to <a href="http://localhost:3000/hello-world">http://localhost:3000/hello-world</a> and you should be able to see the new page.</li>
|
||||
<li>Change the text within the <code><p>...</p></code> to "I can write JSX here!". The browser should refresh automatically to reflect the changes.</li>
|
||||
<li>Change the text within the <code><p>...</p></code> to "I can write JSX here!" and save the file again. The browser should refresh automatically to reflect the change.</li>
|
||||
</ol>
|
||||
<pre><code class="hljs css language-diff"><span class="hljs-deletion">- <p>This is my first page!</p></span>
|
||||
<span class="hljs-addition">+ <p>I can write JSX here!</p></span>
|
||||
|
@ -154,7 +157,7 @@ id sem consectetuer libero luctus adipiscing.</p>
|
|||
</ol>
|
||||
<p>You've created your first documentation page on Docusaurus!</p>
|
||||
<p>Learn more about creating docs pages <a href="navigation">here</a>.</p>
|
||||
</span></div></article></div><div class="docs-prevnext"><a class="docs-prev button" href="/docs/zh-CN/next/tutorial-create-new-site"><span class="arrow-prev">← </span><span>Create a New Site</span></a><a class="docs-next button" href="/docs/zh-CN/next/tutorial-publish-site"><span>Publish the Site</span><span class="arrow-next"> →</span></a></div></div></div><nav class="onPageNav"><ul class="toc-headings"><li><a href="#creating-a-regular-page">Creating a Regular Page</a></li><li><a href="#create-a-documentation-page">Create a Documentation Page</a></li><li><a href="#markdown-syntax">Markdown Syntax</a></li></ul></nav></div><footer class="nav-footer" id="footer"><section class="sitemap"><a href="/" class="nav-home"><img src="/img/docusaurus_monochrome.svg" alt="Docusaurus" width="66" height="58"/></a><div class="footerSection"><h5>Docs</h5><a href="
|
||||
</span></div></article></div><div class="docs-prevnext"><a class="docs-prev button" href="/docs/zh-CN/next/tutorial-create-new-site"><span class="arrow-prev">← </span><span>Create a New Site</span></a><a class="docs-next button" href="/docs/zh-CN/next/tutorial-publish-site"><span>Publish the Site</span><span class="arrow-next"> →</span></a></div></div></div><nav class="onPageNav"><ul class="toc-headings"><li><a href="#create-a-regular-page">Create a Regular Page</a></li><li><a href="#create-a-documentation-page">Create a Documentation Page</a></li><li><a href="#markdown-syntax">Markdown Syntax</a></li></ul></nav></div><footer class="nav-footer" id="footer"><section class="sitemap"><a href="/" class="nav-home"><img src="/img/docusaurus_monochrome.svg" alt="Docusaurus" width="66" height="58"/></a><div class="footerSection"><h5>Docs</h5><a href="
|
||||
/docs/zh-CN/installation">Getting Started</a><a href="
|
||||
/docs/zh-CN/versioning">Versioning</a><a href="
|
||||
/docs/zh-CN/translation">Localization</a><a href="
|
||||
|
|
|
@ -131,14 +131,14 @@ v8.15.1
|
|||
<span class="hljs-comment"># or</span>
|
||||
git <span class="hljs-built_in">clone</span> https://github.com/USERNAME/docusaurus-tutorial.git <span class="hljs-comment"># HTTPS</span>
|
||||
</code></pre>
|
||||
<ol start="7">
|
||||
<li><code>cd</code> to the directory for the local clone.</li>
|
||||
</ol>
|
||||
<pre><code class="hljs css language-sh"><span class="hljs-built_in">cd</span> docusaurus-tutorial
|
||||
</code></pre>
|
||||
<h2><a class="anchor" aria-hidden="true" id="install-the-docusaurus-init-command"></a><a href="#install-the-docusaurus-init-command" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Install the Docusaurus init command</h2>
|
||||
<p>Docusaurus comes with a command line tool to help you scaffold a Docusaurus site with some example templates. Let's install the installer!</p>
|
||||
<ol>
|
||||
<li><code>cd</code> to the directory of your local repository.</li>
|
||||
</ol>
|
||||
<pre><code class="hljs css language-sh"><span class="hljs-built_in">cd</span> docusaurus-tutorial
|
||||
</code></pre>
|
||||
<ol start="2">
|
||||
<li>Run the following command:</li>
|
||||
</ol>
|
||||
<pre><code class="hljs css language-sh">npm install --global docusaurus-init
|
||||
|
|
|
@ -131,14 +131,14 @@ v8.15.1
|
|||
<span class="hljs-comment"># or</span>
|
||||
git <span class="hljs-built_in">clone</span> https://github.com/USERNAME/docusaurus-tutorial.git <span class="hljs-comment"># HTTPS</span>
|
||||
</code></pre>
|
||||
<ol start="7">
|
||||
<li><code>cd</code> to the directory for the local clone.</li>
|
||||
</ol>
|
||||
<pre><code class="hljs css language-sh"><span class="hljs-built_in">cd</span> docusaurus-tutorial
|
||||
</code></pre>
|
||||
<h2><a class="anchor" aria-hidden="true" id="install-the-docusaurus-init-command"></a><a href="#install-the-docusaurus-init-command" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Install the Docusaurus init command</h2>
|
||||
<p>Docusaurus comes with a command line tool to help you scaffold a Docusaurus site with some example templates. Let's install the installer!</p>
|
||||
<ol>
|
||||
<li><code>cd</code> to the directory of your local repository.</li>
|
||||
</ol>
|
||||
<pre><code class="hljs css language-sh"><span class="hljs-built_in">cd</span> docusaurus-tutorial
|
||||
</code></pre>
|
||||
<ol start="2">
|
||||
<li>Run the following command:</li>
|
||||
</ol>
|
||||
<pre><code class="hljs css language-sh">npm install --global docusaurus-init
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue