mirror of
https://github.com/facebook/docusaurus.git
synced 2025-05-30 17:37:09 +02:00
* docs: normalize plugin API documentation * Revert change * Use remark plugin * edits * edit again * Fixes
1.4 KiB
1.4 KiB
sidebar_position | id | title | slug |
---|---|---|---|
10 | plugin-sitemap | 📦 plugin-sitemap | /api/plugins/@docusaurus/plugin-sitemap |
import APITable from '@site/src/components/APITable';
This plugin creates sitemaps for your site so that search engine crawlers can crawl your site more accurately.
:::caution production only
This plugin is always inactive in development and only active in production because it works on the build output.
:::
Installation
npm install --save @docusaurus/plugin-sitemap
:::tip
If you use the preset @docusaurus/preset-classic
, you don't need to install this plugin as a dependency.
You can configure this plugin through the preset options.
:::
Configuration
Accepted fields:
Name | Type | Default | Description |
---|---|---|---|
changefreq |
string |
'weekly' |
See sitemap docs |
priority |
number |
0.5 |
See sitemap docs |
Example configuration
You can configure this plugin through preset options or plugin options.
:::tip
Most Docusaurus users configure this plugin through the preset options.
:::
// preset option name: sitemap
// plugin name: @docusaurus/plugin-sitemap
const config = {
changefreq: 'weekly',
priority: 0.5,
};