-
-
Notifications
You must be signed in to change notification settings - Fork 378
Closed
Description
Describe the bug
When I use ElementPlusResolver
to auto import element-plus component In the vue3 project. But it is not auto import in .jsx file
the vite.config.js
like this:
{
plugins:[
AutoImport({
imports: ["vue"],
resolvers: [
ElementPlusResolver(),
IconsResolver({
prefix: "Icon",
}),
],
extensions: ["vue", "jsx", "tsx"],
}),
Components({
resolvers: [
// 自动注册图标组件
IconsResolver({
enabledCollections: ["ep"],
}),
ElementPlusResolver(),
],
extensions: ["vue", "jsx", "tsx"],
}),
]
}
It's only efficient in .vue component. But it's not ok in .jsx
Reproduction
https://github.com/ngd-b/vue-vite/tree/unplugin-vue-components
System Info
mac apple m2 ; chrome
Used Package Manager
npm
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.
Metadata
Metadata
Assignees
Labels
No labels