Open lucasalbuquerque opened 1 year ago
same problem
Refer to the source code implementation. When initializing Context, dirs and root (process. cwd()) will be merged. If you use relative paths, the merged paths will be incorrect. Therefore, you need to change ../../packages/components to packages/components, hoping to be helpful for your problem https://github.com/antfu/unplugin-vue-components/blob/main/src/core/options.ts#L28 https://github.com/antfu/unplugin-vue-components/blob/main/src/core/context.ts#L37
Describe the bug
Addition a relative paths to "dirs" array not working when it's outside the project dir.
My current workspace structure:
vite.config.ts
When I create a new component inside the '../../packages/components' directory it is not being mapped in my src/components.d.ts file.
Reproduction
Above - it contained code
System Info
Used Package Manager
pnpm
Validations