فهرست منبع

Build: delete unremoved comments in umd module `lib/index.js`

fixed #14230
Zhi 6 سال پیش
والد
کامیت
6d05ccc882
1فایلهای تغییر یافته به همراه12 افزوده شده و 0 حذف شده
  1. 12 0
      build/webpack.conf.js

+ 12 - 0
build/webpack.conf.js

@@ -1,6 +1,7 @@
 const path = require('path');
 const ProgressBarPlugin = require('progress-bar-webpack-plugin');
 const VueLoaderPlugin = require('vue-loader/lib/plugin');
+const TerserPlugin = require('terser-webpack-plugin');
 
 const config = require('./config');
 
@@ -26,6 +27,17 @@ module.exports = {
   externals: {
     vue: config.vue
   },
+  optimization: {
+    minimizer: [
+      new TerserPlugin({
+        terserOptions: {
+          output: {
+            comments: false
+          }
+        },
+      })
+    ]
+  },
   performance: {
     hints: false
   },