forked from devsam/core
build: devtool 결과 최적화
This commit is contained in:
+6
-4
@@ -58,7 +58,9 @@ module.exports = (env, argv) => {
|
||||
for (const [entry, filePath] of Object.entries(build_exports.ingame) ?? []) {
|
||||
entryIngame[entry] = `${tsDir}/${filePath}`;
|
||||
}
|
||||
const cacheDirectory = path.resolve(__dirname, 'node_modules/.cache/webpack')
|
||||
const cacheDirectory = path.resolve(__dirname, 'node_modules/.cache/webpack');
|
||||
|
||||
const devtool = mode != 'production' ? 'eval-source-map' : (env.WEBPACK_WATCH ? 'source-map' : undefined);
|
||||
|
||||
const optimization = {
|
||||
splitChunks: {
|
||||
@@ -104,7 +106,7 @@ module.exports = (env, argv) => {
|
||||
filename: '[name].js',
|
||||
path: resolve(outputPath, 'vue')
|
||||
},
|
||||
devtool: 'source-map',
|
||||
devtool,
|
||||
optimization,
|
||||
module: {
|
||||
rules: [
|
||||
@@ -215,7 +217,7 @@ module.exports = (env, argv) => {
|
||||
filename: '[name].js',
|
||||
path: resolve(outputPath, 'ts')
|
||||
},
|
||||
devtool: 'source-map',
|
||||
devtool,
|
||||
optimization,
|
||||
module: {
|
||||
rules: [{
|
||||
@@ -297,7 +299,7 @@ module.exports = (env, argv) => {
|
||||
filename: '[name].js',
|
||||
path: resolve(__dirname, 'dist_js', 'gateway')
|
||||
},
|
||||
devtool: 'source-map',
|
||||
devtool,
|
||||
optimization,
|
||||
module: {
|
||||
rules: [{
|
||||
|
||||
Reference in New Issue
Block a user