From 145b1f5968314b98a28a6a93658d3c332179011c Mon Sep 17 00:00:00 2001 From: neverland Date: Fri, 26 Feb 2021 11:26:25 +0800 Subject: [PATCH] perf: disable enableObjectSlots to reduce bundle size (#8226) --- babel.config.js | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/babel.config.js b/babel.config.js index c76ad6dce..30fb8cf78 100644 --- a/babel.config.js +++ b/babel.config.js @@ -1,5 +1,11 @@ module.exports = { presets: [ - ['@vant/cli/preset', { loose: process.env.BUILD_TARGET === 'package' }], + [ + '@vant/cli/preset', + { + loose: process.env.BUILD_TARGET === 'package', + enableObjectSlots: false, + }, + ], ], };