mirror of
https://github.com/wallabag/wallabag.git
synced 2024-12-17 05:06:28 +00:00
dce3c84c9c
Update javascript deps to latest version. Rebuild assets - Keep `stylehint` in a lower version because starting at v9.0.0 it generates too much errors. We might fix them later. - Don't touch `materialize-css` to avoid too much side effect. We might update it later (to 1.0.0).
65 lines
1.5 KiB
JavaScript
65 lines
1.5 KiB
JavaScript
const { merge } = require('webpack-merge');
|
|
const webpack = require('webpack');
|
|
const commonConfig = require('./common.js');
|
|
|
|
module.exports = function () {
|
|
return merge(commonConfig(), {
|
|
devtool: 'eval-source-map',
|
|
output: {
|
|
filename: '[name].dev.js',
|
|
},
|
|
mode: 'development',
|
|
devServer: {
|
|
hot: true,
|
|
// enable HMR on the server
|
|
contentBase: './web',
|
|
// match the output path
|
|
},
|
|
plugins: [
|
|
new webpack.HotModuleReplacementPlugin(),
|
|
],
|
|
module: {
|
|
rules: [
|
|
{
|
|
enforce: 'pre',
|
|
test: /\.js$/,
|
|
loader: 'eslint-loader',
|
|
exclude: /node_modules/,
|
|
},
|
|
{
|
|
test: /\.js$/,
|
|
exclude: /(node_modules)/,
|
|
use: {
|
|
loader: 'babel-loader',
|
|
options: {
|
|
presets: ['@babel/preset-env']
|
|
},
|
|
},
|
|
},
|
|
{
|
|
test: /\.(s)?css$/,
|
|
use: [
|
|
'style-loader',
|
|
{
|
|
loader: 'css-loader',
|
|
options: {
|
|
importLoaders: 1,
|
|
},
|
|
},
|
|
{
|
|
loader: 'postcss-loader',
|
|
options: {
|
|
plugins: [require('autoprefixer')({})],
|
|
},
|
|
},
|
|
'sass-loader',
|
|
],
|
|
},
|
|
{
|
|
test: /\.(jpg|png|gif|svg|ico|eot|ttf|woff|woff2)$/,
|
|
use: 'url-loader',
|
|
},
|
|
],
|
|
},
|
|
});
|
|
};
|