unplugin / unplugin-vue-components

📲 On-demand components auto importing for Vue
https://www.npmjs.com/package/unplugin-vue-components
MIT License
3.65k stars 341 forks source link

Wrong component name for folders with dash (-) #738

Closed KarmaBlackshaw closed 2 months ago

KarmaBlackshaw commented 4 months ago

Describe the bug

When nested component's parent folder has dash (-) it gives off a wrong component name.

RoutedMessagesIdePanel: typeof import('./src/components/routed-messages/RoutedMessagesSidePanel.vue')['default']

Right now, changing the parent folder to routedMessages works

Reproduction

https://stackblitz.com/edit/vitejs-vite-vtvczj?file=components.d.ts

System Info

System:
    OS: Windows 11 10.0.22621
    CPU: (12) x64 AMD Ryzen 5 3600 6-Core Processor
    Memory: 12.74 GB / 31.95 GB
  Binaries:
    Node: 16.18.1 - C:\Program Files\nodejs\node.EXE
    npm: 8.19.2 - C:\Program Files\nodejs\npm.CMD
  Browsers:
    Edge: Chromium (121.0.2277.128)
    Internet Explorer: 11.0.22621.1

Used Package Manager

npm

Validations

stackblitz[bot] commented 4 months ago

Fix this issue in StackBlitz Codeflow Start a new pull request in StackBlitz Codeflow.