Skip to content

Commit

Permalink
chore(deps-dev): bump eslint from 8.26.0 to 9.0.0 (#1828)
Browse files Browse the repository at this point in the history
* chore(deps-dev): bump eslint from 8.26.0 to 9.0.0

Bumps [eslint](https://github.com/eslint/eslint) from 8.26.0 to 9.0.0.
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/main/CHANGELOG.md)
- [Commits](eslint/eslint@v8.26.0...v9.0.0)

---
updated-dependencies:
- dependency-name: eslint
  dependency-type: direct:development
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>

* update with latest eslint version

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Denis Ah-Kang <denis@w3.org>
  • Loading branch information
dependabot[bot] and deniak committed Apr 18, 2024
1 parent 87adebc commit 67d6236
Show file tree
Hide file tree
Showing 22 changed files with 177 additions and 222 deletions.
1 change: 0 additions & 1 deletion .eslintignore

This file was deleted.

52 changes: 0 additions & 52 deletions .eslintrc.json

This file was deleted.

1 change: 0 additions & 1 deletion app.js
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,6 @@ io.on('connection', socket => {
);
let profile;
try {
// eslint-disable-next-line node/no-unsupported-features/es-syntax
profile = await import(`./lib/profiles/${profilePath}`);
} catch (err) {
return socket.emit('exception', {
Expand Down
55 changes: 55 additions & 0 deletions eslint.config.cjs
Original file line number Diff line number Diff line change
@@ -0,0 +1,55 @@
[
{
extends: ['airbnb-base', 'prettier'],
plugins: ['prettier'],
rules: {
'prettier/prettier': 'error',
'no-shadow': 'off',
'consistent-return': 'warn',
'no-param-reassign': 'off',
strict: 'off',
'global-require': 'off',
'no-restricted-syntax': 'warn',
'guard-for-in': 'warn',
'prefer-destructuring': 'warn',
'import/prefer-default-export': 'off',
'import/extensions': 'off',
},
ignores: ['doc/api'],
overrides: [
{
files: ['public/js/*.js'],
env: {
browser: true,
jquery: true,
es6: true,
},
rules: {},
},
{
files: ['app.js', 'lib/**/*.js', 'tools/**/*.js'],
plugins: ['node'],
parserOptions: {
ecmaVersion: 2020,
sourceType: 'module',
},
extends: ['plugin:node/recommended'],
},
{
files: ['test/**/*.js'],
env: {
mocha: true,
},
rules: {
'node/no-unpublished-require': 'off',
},
plugins: ['node'],
extends: 'plugin:node/recommended',
parserOptions: {
ecmaVersion: 2022,
sourceType: 'module',
},
},
],
},
];
1 change: 0 additions & 1 deletion lib/l10n-en_GB.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
/* eslint-disable no-template-curly-in-string */
export const messages = {
// Generic
'generic.sotd.not-found':
Expand Down
1 change: 0 additions & 1 deletion lib/l10n.js
Original file line number Diff line number Diff line change
Expand Up @@ -150,7 +150,6 @@ export function message(profileCode, rule, key, extra) {
);
}
result.message = result.message.replace(
// eslint-disable-next-line prefer-regex-literals
new RegExp(`@{year}`, 'g'),
new Date().getFullYear()
);
Expand Down
2 changes: 0 additions & 2 deletions lib/rules/headers/dl.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
/* eslint-disable */

// must have dl, with:
// dts containing "This Version", "Latest Version", "Previous Version" in that order
// this version is https://www.w3.org/TR/2013/WD-shortname-2013MMDD/
Expand Down
1 change: 0 additions & 1 deletion lib/rules/headers/editor-participation.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
/* eslint-disable */
import w3cApi from 'node-w3capi';

const self = {
Expand Down
2 changes: 0 additions & 2 deletions lib/rules/headers/shortname.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
/* eslint-disable */

// This rule is to check shortnames mentioned in dts
// this version is https://www.w3.org/TR/2013/WD-shortname-2013MMDD/
// latest version is https://www.w3.org/TR/shortname/
Expand Down
2 changes: 0 additions & 2 deletions lib/throttled-ua.js
Original file line number Diff line number Diff line change
Expand Up @@ -29,15 +29,13 @@ function fixEnd(req) {
export const get = process.env.NO_THROTTLE
? sua.get
: function () {
// eslint-disable-next-line prefer-spread, prefer-rest-params
const req = sua.get.apply(sua, arguments);
return fixEnd(req);
};

export const post = process.env.NO_THROTTLE
? sua.post
: function () {
// eslint-disable-next-line prefer-spread, prefer-rest-params
const req = sua.post.apply(sua, arguments);
return fixEnd(req);
};
3 changes: 0 additions & 3 deletions lib/util.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@ import fs from 'fs';
import { dirname, resolve } from 'path';
import { fileURLToPath } from 'url';

// eslint-disable-next-line no-underscore-dangle
const __dirname = dirname(fileURLToPath(import.meta.url));

const filesTR = fs.readdirSync(`${__dirname}/profiles/TR/`);
Expand Down Expand Up @@ -82,7 +81,6 @@ const buildProcessParamsFunction = function () {
return async function (params, base, constraints) {
const result = base ? JSON.parse(JSON.stringify(base)) : {};
let originFound = false;
// eslint-disable-next-line no-restricted-syntax
for (const p in params) {
if (
p === 'url' ||
Expand All @@ -108,7 +106,6 @@ const buildProcessParamsFunction = function () {
);

if (profilePath)
// eslint-disable-next-line
result[p] = await import(
`../lib/profiles/${profilePath}`
);
Expand Down
1 change: 0 additions & 1 deletion lib/views.js
Original file line number Diff line number Diff line change
Expand Up @@ -133,7 +133,6 @@ const formatRules = function (sections, common) {
}
result += '</ul>\n';
result = result.replace(
// eslint-disable-next-line prefer-regex-literals
new RegExp(`@{year}`, 'g'),
new Date().getFullYear()
);
Expand Down
Loading

0 comments on commit 67d6236

Please sign in to comment.