1.0.0 • Published 2 years ago
esbuild-plugin-antd-patch v1.0.0
an esbuild plugin to fix the defect of ant-design-vue in vite.
Background
I guess that esbuild can't parse 'import * as xxx from xxx'. I try to change it to 'import xxx from xxx', and esbuild can parse it normally. This is the birth of the plugin. https://github.com/vueComponent/ant-design-vue/blob/1.x/components/_util/moment-util.js#L2
Usage
npm install esbuild-plugin-antd-patch -D
// vite.config.js
import antdPatch from 'esbuild-plugin-antd-patch'
import { defineConfig } from 'vite'
export default defineConfig({
optimizeDeps: {
esbuildOptions: {
plugins: [
antdPatch()
]
}
}
})
Git Contribution submission specification
feat
Add new featuresfix
Fix the problem/BUGstyle
The code style is related and does not affect the running resultperf
Optimization/performance improvementrefactor
Refactorrevert
Undo edittest
Test relateddocs
Documentation/noteschore
Dependency update/scaffolding configuration modification etc.workflow
Workflow improvementsci
Continuous integrationtypes
Type definition file changeswip
In development
License
1.0.0
2 years ago