From: Eduardo San Martin Morote Date: Sun, 17 Aug 2025 13:12:17 +0000 (+0200) Subject: chore: fixed warn X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=282cd9b0afbaa5bd5c3dbdcaaf8c3800cf41554e;p=thirdparty%2Fvuejs%2Frouter.git chore: fixed warn --- diff --git a/packages/router/src/experimental/route-resolver/resolver-fixed.ts b/packages/router/src/experimental/route-resolver/resolver-fixed.ts index 375af5d8..25e11b17 100644 --- a/packages/router/src/experimental/route-resolver/resolver-fixed.ts +++ b/packages/router/src/experimental/route-resolver/resolver-fixed.ts @@ -182,7 +182,7 @@ export function createFixedResolver< throw new Error(`Record "${String(name)}" not found`) } - if (typeof to === 'object' && to.hash && to.hash.startsWith('#')) { + if (typeof to === 'object' && to.hash && !to.hash.startsWith('#')) { warn( `A \`hash\` should always start with the character "#". Replace "${to.hash}" with "#${to.hash}".` )