Skip to content

Commit

Permalink
docs: document permalink upgrade
Browse files Browse the repository at this point in the history
  • Loading branch information
posva committed Aug 20, 2021
1 parent fcde810 commit 61b61a0
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions docs/guide/markdown.md
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,6 @@ Outbound links automatically get `target="_blank" rel="noopener noreferrer"`:
title: Blogging Like a Hacker
lang: en-US
---

```

This data will be available to the rest of the page, along with all custom and theming components.
Expand Down Expand Up @@ -404,10 +403,15 @@ You can also use a [VS Code region](https://code.visualstudio.com/docs/editor/co
VitePress uses [markdown-it](https://github.com/markdown-it/markdown-it) as the Markdown renderer. A lot of the extensions above are implemented via custom plugins. You can further customize the `markdown-it` instance using the `markdown` option in `.vitepress/config.js`:

```js
const anchor = require('markdown-it-anchor')

module.exports = {
markdown: {
// options for markdown-it-anchor
anchor: { permalink: false },
// https://github.com/valeriangalliat/markdown-it-anchor#permalinks
anchor: {
permalink: anchor.permalink.headerLink()
},

// options for markdown-it-toc
toc: { includeLevel: [1, 2] },
Expand Down

0 comments on commit 61b61a0

Please sign in to comment.