How to auto import icon set with plural names?
nova1751 opened this issue · comments
Describe the bug
I'm very confused about how to auto-import icons like the picture below,I tried the forms like <i-gravity-ui-cloud-gear />
and <i-GravityUI-cloud-gear />
but it didn't work.
Reproduction
1
System Info
System:
OS: Windows 11 10.0.22631
CPU: (20) x64 12th Gen Intel(R) Core(TM) i7-12700H
Memory: 1.90 GB / 15.71 GB
Binaries:
Node: 16.20.2 - C:\Program Files\nodejs\node.EXE
Yarn: 1.22.21 - C:\Program Files\nodejs\yarn.CMD
npm: 8.19.4 - C:\Program Files\nodejs\npm.CMD
pnpm: 8.12.0 - C:\Program Files\nodejs\pnpm.CMD
Browsers:
Edge: Chromium (120.0.2210.77)
Internet Explorer: 11.0.22621.1
Used Package Manager
pnpm
Validations
- Follow our Code of Conduct
- Read the Contributing Guide.
- Check that there isn't already an issue that reports the same bug to avoid creating a duplicate.
- Check that this is a concrete bug. For Q&A, please open a GitHub Discussion instead.
- The provided reproduction is a minimal reproducible of the bug.
Use :
to separate collection and icon: <i-gravity-ui:cloud-gear />
what fw are you using?
what fw are you using?
"vite": "^4.4.9",
"vue": "^3.3.12",
@nova1751 it seems gravity-ui
collection missing (should be very new), add it to resolver options via enabledCollections: ['gravity-ui'],
to IconResolver
: https://stackblitz.com/edit/unplugin-unplugin-icons-rupzop?file=vite.config.ts,App.vue
Next time check examples readme page to provide a playground.
Next time check examples readme page to provide a playground.
Oh, I see.Thanks for your help.