From 2dc9c456421c7c10f3c83c6b9d39b96982b931cd Mon Sep 17 00:00:00 2001 From: Andras Schmelczer Date: Wed, 21 Sep 2022 21:56:44 +0200 Subject: [PATCH] Update build settings --- tsconfig.json | 2 +- webpack.config.js | 17 +++++------------ 2 files changed, 6 insertions(+), 13 deletions(-) diff --git a/tsconfig.json b/tsconfig.json index 5563c76..e01ac23 100644 --- a/tsconfig.json +++ b/tsconfig.json @@ -7,6 +7,6 @@ "sourceMap": true, "strict": true, "allowJs": true, - "lib": ["dom", "es2017"] + "lib": ["dom"] } } diff --git a/webpack.config.js b/webpack.config.js index 6ca0496..f6d344b 100644 --- a/webpack.config.js +++ b/webpack.config.js @@ -55,7 +55,7 @@ module.exports = (env, argv) => ({ ], }, { - test: /\.(pdf)$/i, + test: /\.pdf$/i, use: { loader: 'file-loader', options: { @@ -69,7 +69,7 @@ module.exports = (env, argv) => ({ use: 'svg-inline-loader', }, { - test: /no-change.*$/i, + test: /no-change/i, use: { loader: 'file-loader', options: { @@ -97,26 +97,19 @@ module.exports = (env, argv) => ({ use: [ 'ts-loader', { - // for removing whitespace from template strings + // for removing whitespace (mainly from template strings) which are not part of comments loader: 'string-replace-loader', options: { - search: /`\s+`/gs, + search: /(?\s+<`/gs, - replace: '><', - }, - }, ], }, ], }, resolve: { - extensions: ['.ts', '.js'], + extensions: ['.ts'], }, output: { clean: true,