File tree 1 file changed +4
-3
lines changed
1 file changed +4
-3
lines changed Original file line number Diff line number Diff line change @@ -96,7 +96,7 @@ function vue2JsxPlugin(options: Options = {}): Plugin {
96
96
// use id for script blocks in Vue SFCs (e.g. `App.vue?vue&type=script&lang.jsx`)
97
97
// use filepath for plain jsx files (e.g. App.jsx)
98
98
if ( filter ( id ) || filter ( filepath ) ) {
99
- const plugins = [ importMeta , ... babelPlugins ]
99
+ const plugins = [ importMeta ]
100
100
const presets = [
101
101
[ jsx , {
102
102
compositionAPI : 'native' ,
@@ -110,10 +110,11 @@ function vue2JsxPlugin(options: Options = {}): Plugin {
110
110
( r ) => r . default
111
111
) ,
112
112
// @ts -ignore
113
- { isTSX : true , allowExtensions : true }
113
+ { isTSX : true , allowExtensions : true , allowDeclareFields : true }
114
114
] )
115
115
}
116
-
116
+ // custom babel plugins should put *after* ts plugin
117
+ plugins . push ( ...babelPlugins )
117
118
const result = babel . transformSync ( code , {
118
119
babelrc : false ,
119
120
ast : true ,
You can’t perform that action at this time.
0 commit comments