1
0
mirror of https://github.com/BookStackApp/BookStack.git synced 2024-11-23 19:32:29 +01:00
BookStack/webpack.config.js
Dan Brown 540119f133
Moved sass build out of webpack, updated npm deps
Moving sass out of webpack cleans the setup quite considerably and
brings a good speed improvement.
Made use of npm-run-all so the previous commands still run like before.
2020-06-27 16:52:26 +01:00

20 lines
415 B
JavaScript

const path = require('path');
const dev = process.env.NODE_ENV !== 'production';
const config = {
target: 'web',
mode: dev? 'development' : 'production',
entry: {
app: './resources/js/index.js',
},
output: {
filename: '[name].js',
path: path.resolve(__dirname, 'public/dist')
},
};
if (dev) {
config['devtool'] = 'inline-source-map';
}
module.exports = config;