Skip to content

Commit 9c3cf32

Browse files
committed
chore: enableObjectSlots of @vue/babel-plugin-jsx should be false
1 parent fb5d2e5 commit 9c3cf32

File tree

3 files changed

+6
-3
lines changed

3 files changed

+6
-3
lines changed

antd-tools/getBabelCommonConfig.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ module.exports = function(modules) {
88
isTSX: true,
99
},
1010
],
11-
[resolve('@vue/babel-plugin-jsx'), { mergeProps: false }],
11+
[resolve('@vue/babel-plugin-jsx'), { mergeProps: false, enableObjectSlots: false }],
1212
resolve('@babel/plugin-proposal-optional-chaining'),
1313
resolve('@babel/plugin-transform-object-assign'),
1414
resolve('@babel/plugin-proposal-object-rest-spread'),

antd-tools/getWebpackConfig.js

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -97,7 +97,10 @@ function getWebpackConfig(modules) {
9797
options: {
9898
presets: [resolve('@babel/preset-env')],
9999
plugins: [
100-
[resolve('@vue/babel-plugin-jsx'), { mergeProps: false }],
100+
[
101+
resolve('@vue/babel-plugin-jsx'),
102+
{ mergeProps: false, enableObjectSlots: false },
103+
],
101104
resolve('@babel/plugin-proposal-object-rest-spread'),
102105
],
103106
},

webpack.config.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ const babelConfig = {
3333
style: true,
3434
},
3535
],
36-
['@vue/babel-plugin-jsx', { mergeProps: false }],
36+
['@vue/babel-plugin-jsx', { mergeProps: false, enableObjectSlots: false }],
3737
'@babel/plugin-proposal-optional-chaining',
3838
'@babel/plugin-transform-object-assign',
3939
'@babel/plugin-proposal-object-rest-spread',

0 commit comments

Comments
 (0)