We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent fc0c8df commit 46c5bd1Copy full SHA for 46c5bd1
1 file changed
docs/scripts.js
@@ -4,6 +4,7 @@
4
5
const isHeading = el => el && el.nodeType === 1 && /^H[1-6]$/.test(el.tagName);
6
const headers = root.querySelectorAll('h2, h3, h4, h5, h6');
7
+ const ids = new Set();
8
headers.forEach(h => {
9
let id = h.id || h.textContent.trim().toLowerCase().replace(/\W+/g, '-');
10
let base = id;
0 commit comments