Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Astro Icons not properly being found when integration comes as part of a library #240

Open
windmillcode0 opened this issue Oct 2, 2024 · 2 comments

Comments

@windmillcode0
Copy link

What version of astro-icon are you using?

v1.1.1

Astro Info

Astro                    v4.15.10
Node                     v20.17.0
System                   Windows (x64)
Package Manager          npm
Output                   static
Adapter                  none
Integrations             @astrojs/starlight

If this issue only occurs in one browser, which browser is a problem?

No response

Describe the Bug

So it seems even though I added the icon integration and the library install the required packages in its dependencies it still claim to not be able to find the icon set

What's the expected result?

find the icon set and the side bar shows nothing but a chevron as intended
The miminal repo is here https:/windmillcode0/astro-icon-in-astro-lib-issue
because it would be rather hard to install a library in stackblitz via npm link

Link to Minimal Reproducible Example

https://stackblitz.com/edit/withastro-astro-vtd3jq?file=issue-lib%2Foverrides%2FSidebar.astro

@windmillcode0
Copy link
Author

I referenced this issue to no avail #171

@windmillcode0
Copy link
Author

windmillcode0 commented Oct 3, 2024

Greetings found the issue so it looks like you just need to mention (not even install) "@iconify-json/mdi": "^1.1.68", "@iconify/json": "^2.2.239", in the package.json of the consumer not the library, this is a terrible way of doing things I believe the library should look up node_modules and not at all reference the consumer package.json if its indeed looking for the iconset

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant