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

页面中引入一个同名组件,看上去被src/components中的组件覆盖 #717

Open
quixote1304629 opened this issue Nov 24, 2023 · 0 comments

Comments

@quixote1304629
Copy link

quixote1304629 commented Nov 24, 2023

Describe the bug

库版本
vue2.7
"unplugin-vue-components": "^0.25.2"
"webpack": "^5.76.0

vue.config.js配置
image

组件层级
src
--componnets
----A.vue( index.js导出)
--views
----OnePageView.vue
----A.vue

OnePageView.vue
image

问题描述

  1. src/components 有被配置到dirs属性中
  2. OnePageView.vue中渲染的组件理论上期望是 ./A.vue, 但实际上渲染的组件是src/components/A.vue。
  3. 我用的是webpack

有没有大佬在遇到类似组件同名的问题

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