提交 2ff036e3 编写于 作者: fxy060608's avatar fxy060608

fix(mp): disable pathinfo when build

上级 c715ca85
......@@ -202,13 +202,13 @@ module.exports = {
// 使用外层依赖的版本
alias['regenerator-runtime'] = require.resolve('regenerator-runtime')
const output = {
pathinfo: process.env.UNI_MINIMIZE !== 'true',
pathinfo: true,
filename: '[name].js',
chunkFilename: '[id].js',
globalObject: process.env.UNI_PLATFORM === 'mp-alipay' ? 'my' : 'global'
// sourceMapFilename: '../.sourcemap/' + process.env.UNI_PLATFORM + '/[name].js.map'
}
if (process.env.UNI_MINIMIZE === 'true' && process.env.NODE_ENV === 'development') {
if (process.env.NODE_ENV === 'production' || process.env.UNI_MINIMIZE === 'true') {
output.pathinfo = false
}
return {
......@@ -320,4 +320,4 @@ module.exports = {
webpackConfig.plugins.delete('preload')
webpackConfig.plugins.delete('prefetch')
}
}
}
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册