mirror of
https://github.com/wahyd4/docsify.git
synced 2026-08-09 05:16:06 +10:00
fix: digit issue with sidebar (complete REVERT to old method)
This commit is contained in:
@@ -18,7 +18,8 @@ export function slugify(str) {
|
|||||||
.replace(/<[^>\d]+>/g, '')
|
.replace(/<[^>\d]+>/g, '')
|
||||||
.replace(re, '')
|
.replace(re, '')
|
||||||
.replace(/\s/g, '-')
|
.replace(/\s/g, '-')
|
||||||
.replace(/-+/g, '-');
|
.replace(/-+/g, '-')
|
||||||
|
.replace(/^(\d)/, '_$1');
|
||||||
let count = cache[slug];
|
let count = cache[slug];
|
||||||
|
|
||||||
count = hasOwn.call(cache, slug) ? count + 1 : 0;
|
count = hasOwn.call(cache, slug) ? count + 1 : 0;
|
||||||
|
|||||||
Reference in New Issue
Block a user