set preserveWhitespace

This commit is contained in:
Pan 2019-03-08 18:33:36 +08:00
parent 8e0b5624a9
commit 3560fcacf9
1 changed files with 14 additions and 4 deletions

View File

@ -45,7 +45,9 @@ module.exports = {
// parse app.body
// http://expressjs.com/en/4x/api.html#req.body
app.use(bodyParser.json())
app.use(bodyParser.urlencoded({ extended: true }))
app.use(bodyParser.urlencoded({
extended: true
}))
// import ES2015 module from common.js module
const { default: mocks } = require('./mock')
@ -82,7 +84,15 @@ module.exports = {
symbolId: 'icon-[name]'
})
.end()
config.module
.rule('vue')
.use('vue-loader')
.loader('vue-loader')
.tap(options => {
options.compilerOptions.preserveWhitespace = true
return options
})
.end()
config
.when(process.env.NODE_ENV === 'development',
config => config.devtool('cheap-source-map')