Skip to content

Commit

Permalink
fix($markdown): "index" is dropped in a link with "*index" pattern
Browse files Browse the repository at this point in the history
Reported at #996
  • Loading branch information
ulivz committed Nov 25, 2018
1 parent b0133e3 commit e8b78c4
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion packages/@vuepress/markdown/lib/link.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
// 1. adding target="_blank" to external links
// 2. converting internal links to <router-link>

const indexRE = /(.*)(index|readme).md(#?.*)$/i
const indexRE = /(^|.*\/)(index|readme).md(#?.*)$/i

module.exports = (md, externalAttrs) => {
let hasOpenRouterLink = false
Expand Down

0 comments on commit e8b78c4

Please sign in to comment.