Skip to content

Commit

Permalink
fix(cli): 修复代码合并的问题
Browse files Browse the repository at this point in the history
  • Loading branch information
luckyadam committed Jan 7, 2020
1 parent aed9a00 commit 8125a37
Showing 1 changed file with 14 additions and 2 deletions.
16 changes: 14 additions & 2 deletions packages/taro-mini-runner/src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ export default function build (config: IBuildConfig) {
const { babel } = compilePlugins
const webpackConfig = {
mode: config.isWatch ? 'development' : 'production',
devtool: "inline-source-map",
devtool: false,
entry: config.entry,
output: {
filename: '[name].js',
Expand All @@ -30,7 +30,19 @@ export default function build (config: IBuildConfig) {
globalObject: globalObjectMap[config.buildAdapter]
},
resolve: {
extensions: ['.ts', '.tsx', '.js', '.jsx']
extensions
},
target: Targets[config.buildAdapter],
optimization: {
runtimeChunk: {
name: 'runtime'
},
splitChunks: {
chunks: 'all',
maxInitialRequests: Infinity,
minSize: 0,
name: 'vendors'
}
},
module: {
rules: [
Expand Down

0 comments on commit 8125a37

Please sign in to comment.