fixed mysql in bundled app

This commit is contained in:
Jan Prochazka
2020-05-16 08:23:10 +02:00
parent 952dbbf50c
commit 70ab03ad73

View File

@@ -10,23 +10,25 @@ var config = {
target: 'node', target: 'node',
output: { output: {
path: path.resolve(__dirname, 'dist'), path: path.resolve(__dirname, 'dist'),
filename: 'bundle.js' filename: 'bundle.js',
}, },
// module: {
// rules: [ optimization: {
// { minimize: false
// test: /\.js$/, },
// exclude: /node_modules/
// }, // module: {
// ], // rules: [
// }, // {
// test: /\.js$/,
// exclude: /node_modules/
// },
// ],
// },
plugins: [ plugins: [
new webpack.IgnorePlugin({ new webpack.IgnorePlugin({
checkResource(resource) { checkResource(resource) {
const lazyImports = [ const lazyImports = ['pg-native', 'uws'];
'pg-native',
'uws'
];
if (!lazyImports.includes(resource)) { if (!lazyImports.includes(resource)) {
return false; return false;
} }