Skip to content

Commit f1e3bd8

Browse files
Lightning00BladeDevtools-frontend LUCI CQ
authored andcommitted
[eslint] Introduce eslint-plugin-eslint-plugin
Bug: none Change-Id: I733528d699da8aa749d19d249e7752895c5a8195 Reviewed-on: https://chromium-review.googlesource.com/c/devtools/devtools-frontend/+/6259394 Reviewed-by: Benedikt Meurer <[email protected]> Commit-Queue: Nikolay Vitkov <[email protected]>
1 parent 48c2a7d commit f1e3bd8

File tree

106 files changed

+5333
-397
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

106 files changed

+5333
-397
lines changed

eslint.config.mjs

Lines changed: 20 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -7,18 +7,19 @@
77
import stylisticPlugin from '@stylistic/eslint-plugin';
88
import typescriptPlugin from '@typescript-eslint/eslint-plugin';
99
import tsParser from '@typescript-eslint/parser';
10+
import eslintPlugin from 'eslint-plugin-eslint-plugin';
1011
import importPlugin from 'eslint-plugin-import';
1112
import jsdocPlugin from 'eslint-plugin-jsdoc';
1213
import mochaPlugin from 'eslint-plugin-mocha';
1314
import rulesdirPlugin from 'eslint-plugin-rulesdir';
1415
import globals from 'globals';
15-
import {join} from 'path';
16+
import { join } from 'path';
1617

1718
rulesdirPlugin.RULES_DIR = join(
18-
import.meta.dirname,
19-
'scripts',
20-
'eslint_rules',
21-
'lib',
19+
import.meta.dirname,
20+
'scripts',
21+
'eslint_rules',
22+
'lib',
2223
);
2324

2425
/**
@@ -76,6 +77,7 @@ export default [
7677
plugins: {
7778
'@typescript-eslint': typescriptPlugin,
7879
'@stylistic': stylisticPlugin,
80+
'@eslint-plugin': eslintPlugin,
7981
mocha: mochaPlugin,
8082
rulesdir: rulesdirPlugin,
8183
import: importPlugin,
@@ -302,11 +304,11 @@ export default [
302304
parserOptions: {
303305
allowAutomaticSingleRunInference: true,
304306
project: join(
305-
import.meta.dirname,
306-
'config',
307-
'typescript',
308-
'tsconfig.eslint.json',
309-
),
307+
import.meta.dirname,
308+
'config',
309+
'typescript',
310+
'tsconfig.eslint.json',
311+
),
310312
},
311313
},
312314

@@ -500,12 +502,12 @@ export default [
500502
{
501503
// Enforce that any import of models/trace/trace.js names the import Trace.
502504
modulePath: join(
503-
import.meta.dirname,
504-
'front_end',
505-
'models',
506-
'trace',
507-
'trace.js',
508-
),
505+
import.meta.dirname,
506+
'front_end',
507+
'models',
508+
'trace',
509+
'trace.js',
510+
),
509511
importName: 'Trace',
510512
},
511513
],
@@ -696,9 +698,9 @@ export default [
696698
},
697699
{
698700
name: 'EsLint rules test',
699-
files: ['scripts/eslint_rules/test/**/*.js'],
701+
files: ['scripts/eslint_rules/tests/**/*.js'],
700702
rules: {
701-
'rulesdir/no-only-eslint-tests': 'error',
703+
'@eslint-plugin/no-only-tests': 'error',
702704
},
703705
},
704706
{

node_modules/.package-lock.json

Lines changed: 20 additions & 3 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

node_modules/eslint-plugin-eslint-plugin/LICENSE.md

Lines changed: 25 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

node_modules/eslint-plugin-eslint-plugin/README.md

Lines changed: 192 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

node_modules/eslint-plugin-eslint-plugin/configs/all-type-checked.js

Lines changed: 10 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

node_modules/eslint-plugin-eslint-plugin/configs/all.js

Lines changed: 11 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

node_modules/eslint-plugin-eslint-plugin/configs/recommended.js

Lines changed: 11 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

node_modules/eslint-plugin-eslint-plugin/configs/rules-recommended.js

Lines changed: 11 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

node_modules/eslint-plugin-eslint-plugin/configs/rules.js

Lines changed: 11 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)