1
0
mirror of https://github.com/comatory/fb2iCal synced 2025-06-05 22:09:25 +02:00

fix: use buffer fallback for webpack 5 instead of polyfill

This commit is contained in:
Ondřej Synáček
2020-12-25 13:38:30 +01:00
parent 01366fd17e
commit 86cf918aa4
3 changed files with 21 additions and 1 deletions

View File

@@ -35,6 +35,7 @@ module.exports = {
util: require.resolve('util/'),
stream: require.resolve('stream-browserify'),
path: require.resolve('path-browserify'),
buffer: require.resolve('buffer/'),
},
},
module: {
@@ -62,7 +63,6 @@ module.exports = {
template: path.join(__dirname, 'lib', 'static', 'index.html'),
version: pkg.version,
}),
new webpack.ProvidePlugin({ Buffer: ['buffer', 'Buffer'] }),
new webpack.DefinePlugin({
'process.env.NODE_ENV': JSON.stringify(process.env.NODE_ENV),
'process.env.NODE_DEBUG': JSON.stringify(process.env.NODE_DEBUG),