mirror of
https://github.com/facebook/docusaurus.git
synced 2025-05-16 02:27:21 +02:00
parent
46e7d444e4
commit
bdabf15f58
756 changed files with 3330 additions and 2962 deletions
|
@ -128,8 +128,8 @@ MyPage.description = <span class="hljs-string">'My Custom Description'</span>;
|
|||
<span class="hljs-built_in">module</span>.exports = MyPage;
|
||||
</code></pre>
|
||||
<p>Данное свойство будет трансформировано в тег metadata description в созданном HTML.</p>
|
||||
<pre><code class="hljs css language-html"><span class="hljs-tag"><<span class="hljs-name">meta</span> <span class="hljs-attr">property</span>=<span class="hljs-string">"og:description"</span> <span class="hljs-attr">content</span>=<span class="hljs-string">"My Custom Description"</span>/></span>
|
||||
<span class="hljs-tag"><<span class="hljs-name">meta</span> <span class="hljs-attr">name</span>=<span class="hljs-string">"description"</span> <span class="hljs-attr">content</span>=<span class="hljs-string">"My Custom Description"</span>/></span>
|
||||
<pre><code class="hljs css language-html"><span class="hljs-tag"><<span class="hljs-name">meta</span> <span class="hljs-attr">property</span>=<span class="hljs-string">"og:description"</span> <span class="hljs-attr">content</span>=<span class="hljs-string">"My Custom Description"</span> /></span>
|
||||
<span class="hljs-tag"><<span class="hljs-name">meta</span> <span class="hljs-attr">name</span>=<span class="hljs-string">"description"</span> <span class="hljs-attr">content</span>=<span class="hljs-string">"My Custom Description"</span> /></span>
|
||||
</code></pre>
|
||||
<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>Docusaurus предоставляет несколько полезных компонентов React для создания пользовательских страниц, найти эти компоненты можно в модуле <code>CompLibrary</code>. Этот модуль предоставляется как часть Docusaurus в <code>node_modules/docusaurus</code>, поэтому для доступа к нему, страницы из каталога <code>pages</code> временно копируются в <code>node_modules/docusaurus</code> при переработке их в статический HTML. Как видно из файлов-примеров, это означает, что пользовательская страница <code>pages/en/index.js</code> использует путь <code>"../../core/CompLibrary.js"</code> для подключения предоставленных компонентов.</p>
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue