From a9ffbdd74bdbf7d8233517567e8ae31276d0b61e Mon Sep 17 00:00:00 2001 From: dataeaseShu <106045316+dataeaseShu@users.noreply.github.com> Date: Wed, 10 May 2023 11:08:49 +0800 Subject: [PATCH] =?UTF-8?q?feat:=20js=E6=96=87=E4=BB=B6=E6=B7=BB=E5=8A=A0?= =?UTF-8?q?=E7=89=88=E6=9C=AC=E5=8F=B7?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- frontend/vue.config.js | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/frontend/vue.config.js b/frontend/vue.config.js index a7a3746a14..4e993325df 100644 --- a/frontend/vue.config.js +++ b/frontend/vue.config.js @@ -2,6 +2,8 @@ const path = require('path') const defaultSettings = require('./src/settings.js') +const pkg = require('./package.json') + const CopyWebpackPlugin = require('copy-webpack-plugin') // const CompressionPlugin = require('compression-webpack-plugin') const webpack = require('webpack') @@ -48,6 +50,11 @@ module.exports = { '@': resolve('src') } }, + output: { + filename: `js/[name].[contenthash:8].${pkg.version}.js`, + publicPath: '/', + chunkFilename: `js/[name].[contenthash:8].${pkg.version}.js` + }, plugins: [ new CopyWebpackPlugin([ {