From 8c00ba5e157776524b00f38f7b2ef806465d8bf7 Mon Sep 17 00:00:00 2001 From: Jason Huang Date: Mon, 16 Nov 2020 13:25:29 -0500 Subject: [PATCH] fix: set target to node This should make webpack use `require` to load chunks --- webpack.config.js | 1 + 1 file changed, 1 insertion(+) diff --git a/webpack.config.js b/webpack.config.js index c2c7e72..de58b3b 100644 --- a/webpack.config.js +++ b/webpack.config.js @@ -13,6 +13,7 @@ module.exports = [ { entry: './src/index.js', externals: [nodeExternals()], + target: 'node', output: { filename: 'index.js', libraryTarget: 'commonjs2',