mirror of
https://github.com/facebook/docusaurus.git
synced 2025-05-18 03:26:57 +02:00
parent
97f8654433
commit
08fbfd5900
7 changed files with 16 additions and 16 deletions
|
@ -36,7 +36,7 @@
|
|||
<h2><a class="anchor" aria-hidden="true" id="summary-truncation"></a><a href="#summary-truncation" aria-hidden="true" class="hash-link" ><svg 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>Summary Truncation</h2>
|
||||
<p>Use the <code><!--truncate--></code> marker in your blog post to represent what will be shown as the summary when viewing all blog published blog posts. Anything above <code><!--truncate--></code> will be part of the summary. For example:</p>
|
||||
<pre><code class="hljs"><span class="hljs-meta">---</span>
|
||||
<span class="hljs-attr">title:</span> <span class="hljs-string">Truncation</span> <span class="hljs-string">Exmaple</span>
|
||||
<span class="hljs-attr">title:</span> <span class="hljs-string">Truncation</span> <span class="hljs-string">Example</span>
|
||||
<span class="hljs-meta">---</span>
|
||||
|
||||
<span class="hljs-string">All</span> <span class="hljs-string">this</span> <span class="hljs-string">will</span> <span class="hljs-string">be</span> <span class="hljs-string">part</span> <span class="hljs-string">of</span> <span class="hljs-string">the</span> <span class="hljs-string">blog</span> <span class="hljs-string">post</span> <span class="hljs-string">summary.</span>
|
||||
|
@ -53,8 +53,8 @@
|
|||
</code></pre>
|
||||
<h2><a class="anchor" aria-hidden="true" id="changing-how-many-blog-posts-show-on-sidebar"></a><a href="#changing-how-many-blog-posts-show-on-sidebar" aria-hidden="true" class="hash-link" ><svg 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>Changing How Many Blog Posts Show on Sidebar</h2>
|
||||
<p>By default, 5 recent blog posts are shown on the sidebar.</p>
|
||||
<p>You can configure a specifc amount of blog posts to show by adding a <code>blogSidebarCount</code> setting to your <code>siteConfig.js</code>.</p>
|
||||
<p>The available options are an integer repreenting the number of posts you wish to show or a string with the value 'ALL'.</p>
|
||||
<p>You can configure a specific amount of blog posts to show by adding a <code>blogSidebarCount</code> setting to your <code>siteConfig.js</code>.</p>
|
||||
<p>The available options are an integer representing the number of posts you wish to show or a string with the value 'ALL'.</p>
|
||||
<p>Example:</p>
|
||||
<pre><code class="hljs"><span class="hljs-string">blogSidebarCount:</span> <span class="hljs-string">'ALL'</span>
|
||||
</code></pre>
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue