From 1f9093e129b136653a23f82de8bb350570e31950 Mon Sep 17 00:00:00 2001 From: Bojan Rajh Date: Thu, 31 Jul 2025 12:54:40 +0200 Subject: [PATCH] feat: add source param to the check fn --- src/node/markdownToVue.ts | 2 +- src/node/siteConfig.ts | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/node/markdownToVue.ts b/src/node/markdownToVue.ts index 6d2ba98d..f5cee33c 100644 --- a/src/node/markdownToVue.ts +++ b/src/node/markdownToVue.ts @@ -189,7 +189,7 @@ export async function createMarkdownToVueRenderFn( return ignore.test(url) } if (typeof ignore === 'function') { - return ignore(url) + return ignore(url, fileOrig) } return false }) diff --git a/src/node/siteConfig.ts b/src/node/siteConfig.ts index 82ab3162..99751d5e 100644 --- a/src/node/siteConfig.ts +++ b/src/node/siteConfig.ts @@ -114,7 +114,7 @@ export interface UserConfig ignoreDeadLinks?: | boolean | 'localhostLinks' - | (string | RegExp | ((link: string) => boolean))[] + | (string | RegExp | ((link: string, source: string) => boolean))[] /** * Don't force `.html` on URLs.