构建阶段压缩代码、外置map
parent
b67d99e5a5
commit
e19002caca
|
@ -12,6 +12,7 @@ const buildConfig = require('../webpack-build-config')
|
||||||
|
|
||||||
module.exports = merge(baseConfig, {
|
module.exports = merge(baseConfig, {
|
||||||
mode: 'production',
|
mode: 'production',
|
||||||
|
devtool: 'source-map',
|
||||||
entry: {
|
entry: {
|
||||||
main: path.join(__dirname, '../../src/main/index.ts'),
|
main: path.join(__dirname, '../../src/main/index.ts'),
|
||||||
// 'dbService.worker': path.join(__dirname, '../../src/main/worker/dbService/index.ts'),
|
// 'dbService.worker': path.join(__dirname, '../../src/main/worker/dbService/index.ts'),
|
||||||
|
|
|
@ -15,7 +15,7 @@ const buildConfig = require('../webpack-build-config')
|
||||||
|
|
||||||
module.exports = merge(baseConfig, {
|
module.exports = merge(baseConfig, {
|
||||||
mode: 'production',
|
mode: 'production',
|
||||||
devtool: false,
|
devtool: 'source-map',
|
||||||
externals: [
|
externals: [
|
||||||
// ...Object.keys(dependencies || {}).filter(d => !whiteListedModules.includes(d)),
|
// ...Object.keys(dependencies || {}).filter(d => !whiteListedModules.includes(d)),
|
||||||
],
|
],
|
||||||
|
|
|
@ -14,7 +14,7 @@ const buildConfig = require('../webpack-build-config')
|
||||||
|
|
||||||
module.exports = merge(baseConfig, {
|
module.exports = merge(baseConfig, {
|
||||||
mode: 'production',
|
mode: 'production',
|
||||||
devtool: false,
|
devtool: 'source-map',
|
||||||
externals: [
|
externals: [
|
||||||
// ...Object.keys(dependencies || {}).filter(d => !whiteListedModules.includes(d)),
|
// ...Object.keys(dependencies || {}).filter(d => !whiteListedModules.includes(d)),
|
||||||
],
|
],
|
||||||
|
|
|
@ -15,7 +15,7 @@ const buildConfig = require('../webpack-build-config')
|
||||||
|
|
||||||
module.exports = merge(baseConfig, {
|
module.exports = merge(baseConfig, {
|
||||||
mode: 'production',
|
mode: 'production',
|
||||||
devtool: false,
|
devtool: 'source-map',
|
||||||
externals: [
|
externals: [
|
||||||
// ...Object.keys(dependencies || {}).filter(d => !whiteListedModules.includes(d)),
|
// ...Object.keys(dependencies || {}).filter(d => !whiteListedModules.includes(d)),
|
||||||
],
|
],
|
||||||
|
|
|
@ -1,3 +1,3 @@
|
||||||
module.exports = {
|
module.exports = {
|
||||||
minimize: false,
|
minimize: true,
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue