Commit 9f8381e 1 parent 20ea999 commit 9f8381e Copy full SHA for 9f8381e
File tree 1 file changed +2
-8
lines changed
1 file changed +2
-8
lines changed Original file line number Diff line number Diff line change @@ -48,21 +48,15 @@ function vueJsxPlugin(options = {}) {
48
48
name : 'vite:vue-jsx' ,
49
49
50
50
config ( config ) {
51
- const optionsApi = config . define
52
- ? config . define . __VUE_OPTIONS_API__
53
- : undefined
54
- const devTools = config . define
55
- ? config . define . __VUE_PROD_DEVTOOLS__
56
- : undefined
57
51
return {
58
52
// only apply esbuild to ts files
59
53
// since we are handling jsx and tsx now
60
54
esbuild : {
61
55
include : / \. t s $ /
62
56
} ,
63
57
define : {
64
- __VUE_OPTIONS_API__ : optionsApi != null ? optionsApi : true ,
65
- __VUE_PROD_DEVTOOLS__ : devTools != null ? devTools : false
58
+ __VUE_OPTIONS_API__ : config . define ?. __VUE_OPTIONS_API__ ?? true ,
59
+ __VUE_PROD_DEVTOOLS__ : config . define ?. __VUE_PROD_DEVTOOLS__ ?? false
66
60
}
67
61
}
68
62
} ,
You can’t perform that action at this time.
0 commit comments