let build = [] if (process.env.NODE_ENV === 'production') { build = ['transform-remove-console'] } module.exports = { presets: [ '@vue/cli-plugin-babel/preset' ], plugins: [...build] }