File tree Expand file tree Collapse file tree 4 files changed +24
-4
lines changed Expand file tree Collapse file tree 4 files changed +24
-4
lines changed Original file line number Diff line number Diff line change 4141 "xterm-addon-fit" : " ^0.8.0"
4242 },
4343 "devDependencies" : {
44+ "@antfu/eslint-config-vue" : " ^0.43.1" ,
4445 "@types/lodash" : " ^4.14.202" ,
4546 "@types/nprogress" : " ^0.2.0" ,
4647 "@types/sortablejs" : " ^1.15.0" ,
47- "@vue/tsconfig" : " ^0.4.0" ,
48- "@antfu/eslint-config-vue" : " ^0.43.1" ,
4948 "@typescript-eslint/eslint-plugin" : " ^6.13.0" ,
5049 "@typescript-eslint/parser" : " ^6.13.0" ,
5150 "@vitejs/plugin-vue" : " ^4.5.0" ,
5251 "@vitejs/plugin-vue-jsx" : " ^3.1.0" ,
5352 "@vue/compiler-sfc" : " ^3.3.10" ,
53+ "@vue/tsconfig" : " ^0.4.0" ,
5454 "ace-builds" : " ^1.32.0" ,
5555 "autoprefixer" : " ^10.4.16" ,
5656 "eslint" : " ^8.54.0" ,
Original file line number Diff line number Diff line change 1- {"version" :" 2.0.0-beta.6" ,"build_id" :78 ,"total_build" :282 }
1+ {"version" :" 2.0.0-beta.6" ,"build_id" :92 ,"total_build" :296 }
Original file line number Diff line number Diff line change 1- {"version" :" 2.0.0-beta.6" ,"build_id" :78 ,"total_build" :282 }
1+ {"version" :" 2.0.0-beta.6" ,"build_id" :92 ,"total_build" :296 }
Original file line number Diff line number Diff line change @@ -10,6 +10,24 @@ import svgLoader from 'vite-svg-loader'
1010import AutoImport from 'unplugin-auto-import/vite'
1111import DefineOptions from 'unplugin-vue-define-options/vite'
1212
13+ function fixAntdvWarningPlugin ( ) {
14+ return {
15+ name : 'fix-antd-vue-warning' , //
16+ transform ( code : string , id : string ) {
17+ // replace antdv js only
18+ if ( id . includes ( 'ant-design-vue/es/_util/hooks/_vueuse' ) ) {
19+ // replace /* #__PURE__ */ with empty string
20+ const newCode = code . replace ( / \/ \* # _ _ P U R E _ _ \* \/ / g, '' )
21+
22+ return {
23+ code : newCode ,
24+ map : null ,
25+ }
26+ }
27+ } ,
28+ }
29+ }
30+
1331// https://vitejs.dev/config/
1432export default defineConfig ( ( { mode } ) => {
1533 // eslint-disable-next-line n/prefer-global/process
@@ -33,6 +51,8 @@ export default defineConfig(({ mode }) => {
3351 ] ,
3452 } ,
3553 plugins : [
54+ fixAntdvWarningPlugin ( ) ,
55+
3656 vue ( ) ,
3757 vueJsx ( ) ,
3858
You can’t perform that action at this time.
0 commit comments