You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
[Component] [All] Failed to resolve component: el-button If this is a native custom element, make sure to exclude it from component resolution via compilerOptions.isCustomElement.
#16918
Open
wade3po opened this issue
May 20, 2024
· 1 comment
vue.js?v=635cc2bb:1512 [Vue warn]: Failed to resolve component: el-button
If this is a native custom element, make sure to exclude it from component resolution via compilerOptions.isCustomElement.
at
Additional comments
换了node版本也一样,是否是vite版本和element-plus版本有兼容问题
The text was updated successfully, but these errors were encountered:
Bug Type:
Component
Environment
3.4.21
2.7.3
chrom 版本 126.0.6423.2(正式版本) (64 位)
Vite
Reproduction
Related Component
All
Reproduction Link
Github Repo
Steps to reproduce
node 18.12.1
npm create vite@latest
vue
typescript
npm install element-plus --save
npm install -D unplugin-vue-components unplugin-auto-import
// vite.config.ts
import { defineConfig } from "vite";
import vue from "@vitejs/plugin-vue";
import AutoImport from "unplugin-auto-import/vite";
import Components from "unplugin-vue-components/vite";
import { ElementPlusResolver } from "unplugin-vue-components/resolvers";
// https://vitejs.dev/config/
export default defineConfig({
plugins: [
vue(),
AutoImport({
resolvers: [ElementPlusResolver()],
}),
Components({
resolvers: [ElementPlusResolver()],
}),
],
});
What is Expected?
自动导入组件
What is actually happening?
vue.js?v=635cc2bb:1512 [Vue warn]: Failed to resolve component: el-button
If this is a native custom element, make sure to exclude it from component resolution via compilerOptions.isCustomElement.
at
Additional comments
换了node版本也一样,是否是vite版本和element-plus版本有兼容问题
The text was updated successfully, but these errors were encountered: