docs: prepare docs for MDX 2 (#8782)

This commit is contained in:
Sébastien Lorber 2023-03-16 17:02:38 +01:00 committed by GitHub
parent 07c57a1528
commit 9c920c531b
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
36 changed files with 112 additions and 70 deletions

View file

@ -4,6 +4,8 @@ slug: /api/misc/@docusaurus/eslint-plugin/no-html-links
# no-html-links
import APITable from '@site/src/components/APITable';
Ensure that the Docusaurus [`<Link>`](../../../docusaurus-core.mdx#link) component is used instead of `<a>` tags.
The `<Link>` component has prefetching and preloading built-in. It also does build-time broken link detection, and helps Docusaurus understand your site's structure better.

View file

@ -78,7 +78,11 @@ App installation requires the HTTPS protocol and a valid manifest.
We enable users to browse a Docusaurus site offline, by using service-worker precaching.
> ### [What is Precaching?](https://developers.google.com/web/tools/workbox/modules/workbox-precaching)
> <h3>
> <a href="https://developers.google.com/web/tools/workbox/modules/workbox-precaching">
> {'What is Precaching?'}
> </a>
> </h3>
>
> One feature of service workers is the ability to save a set of files to the cache when the service worker is installing. This is often referred to as "precaching", since you are caching content ahead of the service worker being used.
>
@ -120,7 +124,7 @@ Strategies used to turn the offline mode on:
- `appInstalled`: activates for users having installed the site as an app (not 100% reliable)
- `standalone`: activates for users running the app as standalone (often the case once a PWA is installed)
- `queryString`: activates if queryString contains `offlineMode=true` (convenient for PWA debugging)
- `mobile`: activates for mobile users (width <= 996px)
- `mobile`: activates for mobile users (`width <= 996px`)
- `saveData`: activates for users with `navigator.connection.saveData === true`
- `always`: activates for all users

View file

@ -3,6 +3,8 @@ sidebar_position: 2
slug: /api/themes/@docusaurus/theme-classic
---
import APITable from '@site/src/components/APITable';
# 📦 theme-classic
The classic theme for Docusaurus.

View file

@ -37,6 +37,7 @@ An `autogenerated` item is converted by Docusaurus to a **sidebar slice** (also
<details>
<summary>A real-world example</summary>
Consider this file structure:
```bash

View file

@ -76,14 +76,17 @@ Note the terminology we use here.
<b>Current version</b>
</dt>
<dd>
The version placed in the <code>./docs</code> folder.
{'The version placed in the '}
<code>./docs</code>
{' folder.'}
</dd>
<dt>
<b>Latest version / last version</b>
</dt>
<dd>
The version served by default for docs navbar items. Usually has path{' '}
<code>/docs</code>.
{'The version served by default for docs navbar items. Usually has path '}
<code>/docs</code>
{'.'}
</dd>
</dl>

View file

@ -103,7 +103,7 @@ or
<a
target="_blank"
href={require('../../assets/docusaurus-asset-example.docx').default}>
Download this docx
{'Download this docx'}
</a>
[Download this docx using Markdown](../../assets/docusaurus-asset-example.docx)

View file

@ -637,8 +637,10 @@ If you want to embed HTML markup such as anchor links or bold type, you can use
<BrowserWindow>
<pre>
<b>Input: </b>1 2 3 4{'\n'}
<b>Output: </b>"366300745"{'\n'}
<b>{'Input: '}</b>
{'1 2 3 4\n'}
<b>{'Output: '}</b>
{'"366300745"\n'}
</pre>
</BrowserWindow>

View file

@ -106,9 +106,7 @@ Markdown can embed HTML elements, and [`details`](https://developer.mozilla.org/
<summary>
Nested toggle! Some surprise inside...
</summary>
<div>
😲😲😲😲😲
</div>
<div>😲😲😲😲😲</div>
</details>
</div>
</details>
@ -128,9 +126,7 @@ Markdown can embed HTML elements, and [`details`](https://developer.mozilla.org/
<summary>
Nested toggle! Some surprise inside...
</summary>
<div>
😲😲😲😲😲
</div>
<div>😲😲😲😲😲</div>
</details>
</div>
</details>

View file

@ -78,7 +78,11 @@ App installation requires the HTTPS protocol and a valid manifest.
We enable users to browse a Docusaurus site offline, by using service-worker precaching.
> ### [What is Precaching?](https://developers.google.com/web/tools/workbox/modules/workbox-precaching)
> <h3>
> <a href="https://developers.google.com/web/tools/workbox/modules/workbox-precaching">
> {'What is Precaching?'}
> </a>
> </h3>
>
> One feature of service workers is the ability to save a set of files to the cache when the service worker is installing. This is often referred to as "precaching", since you are caching content ahead of the service worker being used.
>
@ -120,7 +124,7 @@ Strategies used to turn the offline mode on:
- `appInstalled`: activates for users having installed the site as an app (not 100% reliable)
- `standalone`: activates for users running the app as standalone (often the case once a PWA is installed)
- `queryString`: activates if queryString contains `offlineMode=true` (convenient for PWA debugging)
- `mobile`: activates for mobile users (width <= 996px)
- `mobile`: activates for mobile users (`width <= 996px`)
- `saveData`: activates for users with `navigator.connection.saveData === true`
- `always`: activates for all users

View file

@ -3,6 +3,8 @@ sidebar_position: 2
slug: /api/themes/@docusaurus/theme-classic
---
import APITable from '@site/src/components/APITable';
# 📦 theme-classic
The classic theme for Docusaurus.

View file

@ -37,6 +37,7 @@ An `autogenerated` item is converted by Docusaurus to a **sidebar slice** (also
<details>
<summary>A real-world example</summary>
Consider this file structure:
```bash

View file

@ -76,14 +76,17 @@ Note the terminology we use here.
<b>Current version</b>
</dt>
<dd>
The version placed in the <code>./docs</code> folder.
{'The version placed in the '}
<code>./docs</code>
{' folder.'}
</dd>
<dt>
<b>Latest version / last version</b>
</dt>
<dd>
The version served by default for docs navbar items. Usually has path{' '}
<code>/docs</code>.
{'The version served by default for docs navbar items. Usually has path '}
<code>/docs</code>
{'.'}
</dd>
</dl>

View file

@ -103,7 +103,7 @@ or
<a
target="_blank"
href={require('../../assets/docusaurus-asset-example.docx').default}>
Download this docx
{'Download this docx'}
</a>
[Download this docx using Markdown](../../assets/docusaurus-asset-example.docx)

View file

@ -635,8 +635,10 @@ If you want to embed HTML markup such as anchor links or bold type, you can use
<BrowserWindow>
<pre>
<b>Input: </b>1 2 3 4{'\n'}
<b>Output: </b>"366300745"{'\n'}
<b>{'Input: '}</b>
{'1 2 3 4\n'}
<b>{'Output: '}</b>
{'"366300745"\n'}
</pre>
</BrowserWindow>

View file

@ -106,9 +106,7 @@ Markdown can embed HTML elements, and [`details`](https://developer.mozilla.org/
<summary>
Nested toggle! Some surprise inside...
</summary>
<div>
😲😲😲😲😲
</div>
<div>😲😲😲😲😲</div>
</details>
</div>
</details>
@ -128,9 +126,7 @@ Markdown can embed HTML elements, and [`details`](https://developer.mozilla.org/
<summary>
Nested toggle! Some surprise inside...
</summary>
<div>
😲😲😲😲😲
</div>
<div>😲😲😲😲😲</div>
</details>
</div>
</details>

View file

@ -78,7 +78,11 @@ App installation requires the HTTPS protocol and a valid manifest.
We enable users to browse a Docusaurus site offline, by using service-worker precaching.
> ### [What is Precaching?](https://developers.google.com/web/tools/workbox/modules/workbox-precaching)
> <h3>
> <a href="https://developers.google.com/web/tools/workbox/modules/workbox-precaching">
> {'What is Precaching?'}
> </a>
> </h3>
>
> One feature of service workers is the ability to save a set of files to the cache when the service worker is installing. This is often referred to as "precaching", since you are caching content ahead of the service worker being used.
>
@ -120,7 +124,7 @@ Strategies used to turn the offline mode on:
- `appInstalled`: activates for users having installed the site as an app (not 100% reliable)
- `standalone`: activates for users running the app as standalone (often the case once a PWA is installed)
- `queryString`: activates if queryString contains `offlineMode=true` (convenient for PWA debugging)
- `mobile`: activates for mobile users (width <= 996px)
- `mobile`: activates for mobile users (`width <= 996px`)
- `saveData`: activates for users with `navigator.connection.saveData === true`
- `always`: activates for all users

View file

@ -3,6 +3,8 @@ sidebar_position: 2
slug: /api/themes/@docusaurus/theme-classic
---
import APITable from '@site/src/components/APITable';
# 📦 theme-classic
The classic theme for Docusaurus.

View file

@ -37,6 +37,7 @@ An `autogenerated` item is converted by Docusaurus to a **sidebar slice** (also
<details>
<summary>A real-world example</summary>
Consider this file structure:
```bash

View file

@ -76,14 +76,17 @@ Note the terminology we use here.
<b>Current version</b>
</dt>
<dd>
The version placed in the <code>./docs</code> folder.
{'The version placed in the '}
<code>./docs</code>
{' folder.'}
</dd>
<dt>
<b>Latest version / last version</b>
</dt>
<dd>
The version served by default for docs navbar items. Usually has path{' '}
<code>/docs</code>.
{'The version served by default for docs navbar items. Usually has path '}
<code>/docs</code>
{'.'}
</dd>
</dl>

View file

@ -103,7 +103,7 @@ or
<a
target="_blank"
href={require('../../assets/docusaurus-asset-example.docx').default}>
Download this docx
{'Download this docx'}
</a>
[Download this docx using Markdown](../../assets/docusaurus-asset-example.docx)

View file

@ -635,8 +635,10 @@ If you want to embed HTML markup such as anchor links or bold type, you can use
<BrowserWindow>
<pre>
<b>Input: </b>1 2 3 4{'\n'}
<b>Output: </b>"366300745"{'\n'}
<b>{'Input: '}</b>
{'1 2 3 4\n'}
<b>{'Output: '}</b>
{'"366300745"\n'}
</pre>
</BrowserWindow>

View file

@ -106,9 +106,7 @@ Markdown can embed HTML elements, and [`details`](https://developer.mozilla.org/
<summary>
Nested toggle! Some surprise inside...
</summary>
<div>
😲😲😲😲😲
</div>
<div>😲😲😲😲😲</div>
</details>
</div>
</details>
@ -128,9 +126,7 @@ Markdown can embed HTML elements, and [`details`](https://developer.mozilla.org/
<summary>
Nested toggle! Some surprise inside...
</summary>
<div>
😲😲😲😲😲
</div>
<div>😲😲😲😲😲</div>
</details>
</div>
</details>

View file

@ -78,7 +78,11 @@ App installation requires the HTTPS protocol and a valid manifest.
We enable users to browse a Docusaurus site offline, by using service-worker precaching.
> ### [What is Precaching?](https://developers.google.com/web/tools/workbox/modules/workbox-precaching)
> <h3>
> <a href="https://developers.google.com/web/tools/workbox/modules/workbox-precaching">
> {'What is Precaching?'}
> </a>
> </h3>
>
> One feature of service workers is the ability to save a set of files to the cache when the service worker is installing. This is often referred to as "precaching", since you are caching content ahead of the service worker being used.
>
@ -120,7 +124,7 @@ Strategies used to turn the offline mode on:
- `appInstalled`: activates for users having installed the site as an app (not 100% reliable)
- `standalone`: activates for users running the app as standalone (often the case once a PWA is installed)
- `queryString`: activates if queryString contains `offlineMode=true` (convenient for PWA debugging)
- `mobile`: activates for mobile users (width <= 996px)
- `mobile`: activates for mobile users (`width <= 996px`)
- `saveData`: activates for users with `navigator.connection.saveData === true`
- `always`: activates for all users

View file

@ -3,6 +3,8 @@ sidebar_position: 2
slug: /api/themes/@docusaurus/theme-classic
---
import APITable from '@site/src/components/APITable';
# 📦 theme-classic
The classic theme for Docusaurus.

View file

@ -37,6 +37,7 @@ An `autogenerated` item is converted by Docusaurus to a **sidebar slice** (also
<details>
<summary>A real-world example</summary>
Consider this file structure:
```bash

View file

@ -76,14 +76,17 @@ Note the terminology we use here.
<b>Current version</b>
</dt>
<dd>
The version placed in the <code>./docs</code> folder.
{'The version placed in the '}
<code>./docs</code>
{' folder.'}
</dd>
<dt>
<b>Latest version / last version</b>
</dt>
<dd>
The version served by default for docs navbar items. Usually has path{' '}
<code>/docs</code>.
{'The version served by default for docs navbar items. Usually has path '}
<code>/docs</code>
{'.'}
</dd>
</dl>

View file

@ -103,7 +103,7 @@ or
<a
target="_blank"
href={require('../../assets/docusaurus-asset-example.docx').default}>
Download this docx
{'Download this docx'}
</a>
[Download this docx using Markdown](../../assets/docusaurus-asset-example.docx)

View file

@ -635,8 +635,10 @@ If you want to embed HTML markup such as anchor links or bold type, you can use
<BrowserWindow>
<pre>
<b>Input: </b>1 2 3 4{'\n'}
<b>Output: </b>"366300745"{'\n'}
<b>{'Input: '}</b>
{'1 2 3 4\n'}
<b>{'Output: '}</b>
{'"366300745"\n'}
</pre>
</BrowserWindow>

View file

@ -106,9 +106,7 @@ Markdown can embed HTML elements, and [`details`](https://developer.mozilla.org/
<summary>
Nested toggle! Some surprise inside...
</summary>
<div>
😲😲😲😲😲
</div>
<div>😲😲😲😲😲</div>
</details>
</div>
</details>
@ -128,9 +126,7 @@ Markdown can embed HTML elements, and [`details`](https://developer.mozilla.org/
<summary>
Nested toggle! Some surprise inside...
</summary>
<div>
😲😲😲😲😲
</div>
<div>😲😲😲😲😲</div>
</details>
</div>
</details>

View file

@ -78,7 +78,11 @@ App installation requires the HTTPS protocol and a valid manifest.
We enable users to browse a Docusaurus site offline, by using service-worker precaching.
> ### [What is Precaching?](https://developers.google.com/web/tools/workbox/modules/workbox-precaching)
> <h3>
> <a href="https://developers.google.com/web/tools/workbox/modules/workbox-precaching">
> {'What is Precaching?'}
> </a>
> </h3>
>
> One feature of service workers is the ability to save a set of files to the cache when the service worker is installing. This is often referred to as "precaching", since you are caching content ahead of the service worker being used.
>
@ -120,7 +124,7 @@ Strategies used to turn the offline mode on:
- `appInstalled`: activates for users having installed the site as an app (not 100% reliable)
- `standalone`: activates for users running the app as standalone (often the case once a PWA is installed)
- `queryString`: activates if queryString contains `offlineMode=true` (convenient for PWA debugging)
- `mobile`: activates for mobile users (width <= 996px)
- `mobile`: activates for mobile users (`width <= 996px`)
- `saveData`: activates for users with `navigator.connection.saveData === true`
- `always`: activates for all users

View file

@ -3,6 +3,8 @@ sidebar_position: 2
slug: /api/themes/@docusaurus/theme-classic
---
import APITable from '@site/src/components/APITable';
# 📦 theme-classic
The classic theme for Docusaurus.

View file

@ -37,6 +37,7 @@ An `autogenerated` item is converted by Docusaurus to a **sidebar slice** (also
<details>
<summary>A real-world example</summary>
Consider this file structure:
```bash

View file

@ -76,14 +76,17 @@ Note the terminology we use here.
<b>Current version</b>
</dt>
<dd>
The version placed in the <code>./docs</code> folder.
{'The version placed in the '}
<code>./docs</code>
{' folder.'}
</dd>
<dt>
<b>Latest version / last version</b>
</dt>
<dd>
The version served by default for docs navbar items. Usually has path{' '}
<code>/docs</code>.
{'The version served by default for docs navbar items. Usually has path '}
<code>/docs</code>
{'.'}
</dd>
</dl>

View file

@ -103,7 +103,7 @@ or
<a
target="_blank"
href={require('../../assets/docusaurus-asset-example.docx').default}>
Download this docx
{'Download this docx'}
</a>
[Download this docx using Markdown](../../assets/docusaurus-asset-example.docx)

View file

@ -635,8 +635,10 @@ If you want to embed HTML markup such as anchor links or bold type, you can use
<BrowserWindow>
<pre>
<b>Input: </b>1 2 3 4{'\n'}
<b>Output: </b>"366300745"{'\n'}
<b>{'Input: '}</b>
{'1 2 3 4\n'}
<b>{'Output: '}</b>
{'"366300745"\n'}
</pre>
</BrowserWindow>

View file

@ -106,9 +106,7 @@ Markdown can embed HTML elements, and [`details`](https://developer.mozilla.org/
<summary>
Nested toggle! Some surprise inside...
</summary>
<div>
😲😲😲😲😲
</div>
<div>😲😲😲😲😲</div>
</details>
</div>
</details>
@ -128,9 +126,7 @@ Markdown can embed HTML elements, and [`details`](https://developer.mozilla.org/
<summary>
Nested toggle! Some surprise inside...
</summary>
<div>
😲😲😲😲😲
</div>
<div>😲😲😲😲😲</div>
</details>
</div>
</details>