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>
This commit is contained in:
silverwind 2020-07-27 23:01:25 +02:00 committed by GitHub
parent 8d6fa00da0
commit 78cbd0ca72
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
5 changed files with 546 additions and 694 deletions

View file

@ -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')) {