fix: markdown link attrs matcher, close #284
This commit is contained in:
parent
ae0bcd2486
commit
1010320cc6
@ -89,7 +89,7 @@ export default defineConfig({
|
|||||||
// https://prismjs.com/
|
// https://prismjs.com/
|
||||||
md.use(Prism)
|
md.use(Prism)
|
||||||
md.use(LinkAttributes, {
|
md.use(LinkAttributes, {
|
||||||
pattern: /^https?:\/\//,
|
matcher: (link: string) => /^https?:\/\//.test(link),
|
||||||
attrs: {
|
attrs: {
|
||||||
target: '_blank',
|
target: '_blank',
|
||||||
rel: 'noopener',
|
rel: 'noopener',
|
||||||
|
Loading…
Reference in New Issue
Block a user