From c8382a1bcb1b291524e49b1762d53c28e427621e Mon Sep 17 00:00:00 2001 From: Maxim Karpov Date: Thu, 16 May 2024 15:40:48 +0300 Subject: [PATCH] fix: change isAbsolute to includes double slashes --- src/transform/plugins/links/index.ts | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/transform/plugins/links/index.ts b/src/transform/plugins/links/index.ts index 20389e09..42daa765 100644 --- a/src/transform/plugins/links/index.ts +++ b/src/transform/plugins/links/index.ts @@ -184,7 +184,8 @@ function processLink(state: StateCore, tokens: Token[], idx: number, opts: ProcO } let newPathname = ''; - if (!isAbsolute(href)) { + + if (!isAbsolute(href) && !href.includes('//')) { newPathname = getPublicPath(opts, file); href = url.format({