mirror of
https://github.com/paperdash/device-epd.git
synced 2024-11-04 12:00:27 +00:00
optimize build for esp32
This commit is contained in:
parent
19b76fd772
commit
72ab301495
@ -1,3 +1,5 @@
|
||||
const webpack = require('webpack');
|
||||
|
||||
module.exports = {
|
||||
"outputDir": "../data/dist",
|
||||
"filenameHashing": false,
|
||||
@ -13,5 +15,19 @@ module.exports = {
|
||||
changeOrigin: true
|
||||
},
|
||||
}
|
||||
},
|
||||
configureWebpack: config => {
|
||||
if (process.env.NODE_ENV === 'production') {
|
||||
// optimize build for esp32
|
||||
return {
|
||||
plugins: [
|
||||
new webpack.optimize.LimitChunkCountPlugin({
|
||||
maxChunks: 1
|
||||
})
|
||||
]
|
||||
}
|
||||
} else {
|
||||
// mutate for development...
|
||||
}
|
||||
}
|
||||
}
|
Loading…
Reference in New Issue
Block a user