Closed FDiskas closed 6 months ago
Hi! π
Firstly, thanks for your work on this project! π
Today I used patch-package to patch astro-icon@0.8.1 for the project I'm working on.
astro-icon@0.8.1
Here is the diff that solved my problem:
diff --git a/node_modules/astro-icon/lib/createIconPack.ts b/node_modules/astro-icon/lib/createIconPack.ts index c49ccae..3045d92 100644 --- a/node_modules/astro-icon/lib/createIconPack.ts +++ b/node_modules/astro-icon/lib/createIconPack.ts @@ -15,7 +15,7 @@ export function createIconPack({ }: CreateIconPackOptions) { if (pkg) { return async (name: string) => { - const baseUrl = new URL(pathToFileURL(resolvePackage(pkg)) + "/"); + const baseUrl = new URL(pathToFileURL(resolvePackage(pkg) ?? '') + "/"); const path = fileURLToPath( new URL(dir ? `${dir}/${name}.svg` : `${name}.svg`, baseUrl) );
This issue body was partially generated by patch-package.
Thanks for the issue! I'm going to close this since Astro Icon v1 has been released, but please open a new issue if you run into anything problems!
Hi! π
Firstly, thanks for your work on this project! π
Today I used patch-package to patch
astro-icon@0.8.1
for the project I'm working on.Here is the diff that solved my problem:
This issue body was partially generated by patch-package.