Skip to content

Commit

Permalink
feat(v2): add onBrokenMarkdownLinks to API docs
Browse files Browse the repository at this point in the history
  • Loading branch information
AmyrAhmady committed Oct 31, 2020
1 parent 15f2b8f commit 58199ae
Show file tree
Hide file tree
Showing 3 changed files with 17 additions and 1 deletion.
2 changes: 1 addition & 1 deletion packages/docusaurus/src/server/configValidation.ts
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ const ConfigSchema = Joi.object({
.default(DEFAULT_CONFIG.onBrokenLinks),
onBrokenMarkdownLinks: Joi.string()
.equal('ignore', 'log', 'warn', 'error', 'throw')
.default(DEFAULT_CONFIG.onBrokenLinks),
.default(DEFAULT_CONFIG.onBrokenMarkdownLinks),
onDuplicateRoutes: Joi.string()
.equal('ignore', 'log', 'warn', 'error', 'throw')
.default(DEFAULT_CONFIG.onDuplicateRoutes),
Expand Down
8 changes: 8 additions & 0 deletions website/docs/api/docusaurus.config.js.md
Original file line number Diff line number Diff line change
Expand Up @@ -108,6 +108,14 @@ The broken links detection is only available for a production build (`docusaurus

:::

### `onBrokenMarkdownLinks`

- Type: `'ignore' | 'log' | 'warn' | 'error' | 'throw'`

The behavior of Docusaurus, when it detects any broken markdown link.

By default, it prints a warning, to let you know about your broken markdown link, but you can change this security if needed.

### `onDuplicateRoutes`

- Type: `'ignore' | 'log' | 'warn' | 'error' | 'throw'`
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -108,6 +108,14 @@ The broken links detection is only available for a production build (`docusaurus

:::

### `onBrokenMarkdownLinks`

- Type: `'ignore' | 'log' | 'warn' | 'error' | 'throw'`

The behavior of Docusaurus, when it detects any broken markdown link.

By default, it prints a warning, to let you know about your broken markdown link, but you can change this security if needed.

### `onDuplicateRoutes`

- Type: `'ignore' | 'log' | 'warn' | 'error' | 'throw'`
Expand Down

0 comments on commit 58199ae

Please sign in to comment.