From f21114a6a7d9a3041fdc1aa61998d1a309c5ec8a Mon Sep 17 00:00:00 2001 From: John Livingston Date: Sat, 10 Apr 2021 03:22:55 +0200 Subject: [PATCH] SourceMap when using NODE_ENV=dev. --- webpack.config.js | 3 +++ 1 file changed, 3 insertions(+) diff --git a/webpack.config.js b/webpack.config.js index 5d45a900..eef992b3 100644 --- a/webpack.config.js +++ b/webpack.config.js @@ -9,6 +9,7 @@ const clientFiles = [ let config = clientFiles.map(f => ({ entry: "./client/" + f + ".ts", + devtool: process.env.NODE_ENV === 'dev' ? 'eval-source-map' : false, module: { rules: [ { @@ -31,6 +32,7 @@ let config = clientFiles.map(f => ({ config.push({ entry: "./conversejs/builtin.js", + devtool: process.env.NODE_ENV === 'dev' ? 'eval-source-map' : false, output: { path: path.resolve(__dirname, "./dist/client/static"), filename: "./builtin.js" @@ -39,6 +41,7 @@ config.push({ config.push({ entry: "./client/settings.ts", + devtool: process.env.NODE_ENV === 'dev' ? 'eval-source-map' : false, module: { rules: [ {