Skip to content

Commit 63c41fb

Browse files
committedJul 17, 2022
fix: Strip custom anchor with capital letters in outline
1 parent d5ed66c commit 63c41fb

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed
 

Diff for: ‎src/node/utils/parseHeader.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ const removeMarkdownTokens = (str: string) =>
3333
.replace(/(\\)(\*|_|`|\!|<|\$)/g, '$2') // remove escape char '\'
3434

3535
const removeCustomAnchor = (str: string) =>
36-
str.replace(/\{#([a-z0-9\-_]+?)\}\s*$/, '') // {#custom-header}
36+
str.replace(/\{#([a-zA-Z0-9\-_]+?)\}\s*$/, '') // {#custom-header}
3737

3838
const trim = (str: string) => str.trim()
3939

0 commit comments

Comments
 (0)