diff --git a/src/index.ts b/src/index.ts index 828b063..dc26c1e 100644 --- a/src/index.ts +++ b/src/index.ts @@ -171,9 +171,9 @@ const FontCarrier: (options: FontCarrierOptions) => Plugin = (options) => { for (const url of urls) { let path: string; if (isAbsolute(url)) { - path = resolve(resolvedConfig.publicDir, url); + path = normalizePath(resolve(resolvedConfig.publicDir, url.slice(1))); } else { - path = resolve(dirname(id), url); + path = normalizePath(resolve(dirname(id), url)); } const font = fontAssets.find(font => font.path === path); if (font) {