From 7b46219624f93b110ea8d6652ce5bc2a44de5073 Mon Sep 17 00:00:00 2001 From: Kang Cheng Date: Fri, 19 Oct 2018 21:56:26 +0100 Subject: [PATCH] Remove target for mailto links Closes https://github.com/docsifyjs/docsify/issues/625 --- src/core/render/compiler.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/core/render/compiler.js b/src/core/render/compiler.js index ed36429d7..90e934c24 100644 --- a/src/core/render/compiler.js +++ b/src/core/render/compiler.js @@ -213,7 +213,7 @@ export class Compiler { } href = router.toURL(href, null, router.getCurrentPath()) } else { - attrs += ` target="${linkTarget}"` + attrs += href.startsWith('mailto:') ? '' : ` target="${linkTarget}"` } if (config.target) {