Skip to content

Commit 025e302

Browse files
committed
docs: fix globals.md anchors
1 parent 6a3434f commit 025e302

File tree

12 files changed

+80
-1151
lines changed

12 files changed

+80
-1151
lines changed

docs/.vitepress/config.js

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,25 @@
1+
import MarkdownIt from 'markdown-it';
2+
import markdownItAttrs from 'markdown-it-attrs';
13
import anchor from 'markdown-it-anchor';
24

5+
const md = new MarkdownIt();
6+
37
export default {
48
title: 'Js-Css Animations',
59
description: 'Animate your web apps or site using Javascript',
10+
markdown: {
11+
anchor: {
12+
getTokensText: tokens => {
13+
return tokens
14+
.filter(t => t.type === 'text' && t.info !== 'entity' && t.content)
15+
.map(t => t.content)
16+
.join('')
17+
.replace(/\s.*$/, '');
18+
},
19+
permalink: anchor.permalink.ariaHidden({
20+
symbol: '§',
21+
}),
22+
},
23+
// anchor: { permalink: true, permalinkBefore: true, permalinkSymbol: '🔗' },
24+
},
625
};

0 commit comments

Comments
 (0)