diff --git a/.eslintrc.json b/.eslintrc.json index bc12bf82..83299996 100644 --- a/.eslintrc.json +++ b/.eslintrc.json @@ -1,6 +1,6 @@ { - "extends": ["eslint:recommended", "plugin:prettier/recommended", "plugin:jsdoc/recommended"], - "plugins": ["prettier", "import", "jsdoc", "jest"], + "extends": ["eslint:recommended", "plugin:import/recommended", "plugin:jsdoc/recommended", "plugin:prettier/recommended"], + "plugins": ["jest"], "env": { "browser": true, "es2022": true, @@ -24,6 +24,8 @@ "rules": { "eqeqeq": "error", "import/order": "error", + "import/extensions": "error", + "import/newline-after-import": "error", "no-param-reassign": "error", "no-prototype-builtins": "off", "no-throw-literal": "error", diff --git a/CHANGELOG.md b/CHANGELOG.md index ebfba62e..4d60c9b5 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -25,6 +25,7 @@ _This release is scheduled to be released on 2024-01-01._ - Update electron to v27 and update other dependencies as well as github actions - Update newsfeed: Use `html-to-text` instead of regex for transform description +- Review ESLint config (#3269) ### Fixed diff --git a/js/app.js b/js/app.js index 18494018..0d675845 100644 --- a/js/app.js +++ b/js/app.js @@ -12,6 +12,7 @@ const fs = require("fs"); const path = require("path"); const envsub = require("envsub"); const Log = require("logger"); + const Server = require(`${__dirname}/server`); const Utils = require(`${__dirname}/utils`); const defaultModules = require(`${__dirname}/../modules/default/defaultmodules`); diff --git a/js/server_functions.js b/js/server_functions.js index 5693ad41..a11e81a5 100644 --- a/js/server_functions.js +++ b/js/server_functions.js @@ -1,6 +1,7 @@ const fs = require("fs"); const path = require("path"); const Log = require("logger"); + const startUp = new Date(); /** diff --git a/modules/default/calendar/calendarfetcherutils.js b/modules/default/calendar/calendarfetcherutils.js index e10a7904..14203289 100644 --- a/modules/default/calendar/calendarfetcherutils.js +++ b/modules/default/calendar/calendarfetcherutils.js @@ -10,6 +10,7 @@ */ const path = require("path"); const moment = require("moment"); + const zoneTable = require(path.join(__dirname, "windowsZones.json")); const Log = require("../../../js/logger"); diff --git a/tests/e2e/animateCSS_spec.js b/tests/e2e/animateCSS_spec.js index 3f7cac83..b0f138c1 100644 --- a/tests/e2e/animateCSS_spec.js +++ b/tests/e2e/animateCSS_spec.js @@ -5,7 +5,7 @@ * 09/2023 * MIT Licensed. */ -const helpers = require("./helpers/global-setup.js"); +const helpers = require("./helpers/global-setup"); describe("AnimateCSS integration Test", () => { // define config file for testing diff --git a/tests/e2e/helpers/basic-auth.js b/tests/e2e/helpers/basic-auth.js index 8307464e..c793085b 100644 --- a/tests/e2e/helpers/basic-auth.js +++ b/tests/e2e/helpers/basic-auth.js @@ -1,6 +1,7 @@ const path = require("path"); const auth = require("express-basic-auth"); const express = require("express"); + const app = express(); const basicAuth = auth({