Skip to content

Commit 3116afe

Browse files
committed
chore: add more markdown tokens to be removed
1 parent c5347c6 commit 3116afe

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

Diff for: lib/util/parseHeaders.js

+5-2
Original file line numberDiff line numberDiff line change
@@ -11,8 +11,11 @@ const unescapeHtml = html => html
1111
.replace(/>/g, '>')
1212

1313
const removeMarkdownToken = str => str
14-
.replace(/`(.*)`/, '$1')
15-
.replace(/\[(.*)\]\(.*\)/, '$1')
14+
.replace(/`(.*)`/, '$1') // ``
15+
.replace(/\[(.*)\]\(.*\)/, '$1') // []()
16+
.replace(/\*\*(.*)\*\*/, '$1') // **
17+
.replace(/\*(.*)\*/, '$1') // *
18+
.replace(/_(.*)_/, '$1') // _
1619

1720
// put here to avoid circular references
1821
const compose = (...processors) => {

0 commit comments

Comments
 (0)