summaryrefslogtreecommitdiffstats
path: root/webpack.config.js
diff options
context:
space:
mode:
authorsilverwind <me@silverwind.io>2020-07-27 23:01:25 +0200
committerGitHub <noreply@github.com>2020-07-27 17:01:25 -0400
commit78cbd0ca72619a25849edc3460ec0c492b838a59 (patch)
treeed76273e7e19c947ae26e226dc740f5a97131e3c /webpack.config.js
parent8d6fa00da06e52cba1aaed5ba2a187fed8cd63de (diff)
downloadgitea-78cbd0ca72619a25849edc3460ec0c492b838a59.tar.gz
gitea-78cbd0ca72619a25849edc3460ec0c492b838a59.zip
Update JS deps and linting config (#12295)
- update js deps to latest versions - remove eslint-plugin-sonarjs to prevent a warning on install. can be added again once it's updated to support eslint 7.x - enable new linting rules from eslint-plugin-unicorn Co-authored-by: techknowlogick <techknowlogick@gitea.io>
Diffstat (limited to 'webpack.config.js')
-rw-r--r--webpack.config.js4
1 files changed, 2 insertions, 2 deletions
diff --git a/webpack.config.js b/webpack.config.js
index 637ff5d94a..42959a50ea 100644
--- a/webpack.config.js
+++ b/webpack.config.js
@@ -21,8 +21,8 @@ for (const path of glob('web_src/less/themes/*.less')) {
const isProduction = process.env.NODE_ENV !== 'development';
-const filterCssImport = (parsedImport, cssFile) => {
- const url = parsedImport && parsedImport.url ? parsedImport.url : parsedImport;
+const filterCssImport = (url, ...args) => {
+ const cssFile = args[1] || args[0]; // resourcePath is 2nd argument for url and 3rd for import
const importedFile = url.replace(/[?#].+/, '').toLowerCase();
if (cssFile.includes('fomantic')) {