Open
Bug 1881697
Opened 1 year ago
Updated 1 year ago
[meta] Replace ESLint environment support
Categories
(Developer Infrastructure :: Lint and Formatting, task, P3)
Developer Infrastructure
Lint and Formatting
Tracking
(Not tracked)
NEW
People
(Reporter: standard8, Unassigned)
References
(Depends on 1 open bug, Blocks 1 open bug)
Details
(Keywords: meta)
ESLint v9 is dropping support for environments, which means we'll need to find other ways of defining groups of globals for particular files.
On the most part, we can do this by file paths or using special naming conventions. We've already started doing this for workers for example (bug 1847110).
This meta will probably be broken down into several parts:
- Replace in-line
/* eslint-env mozilla/chrome-script */
definitions with automatic injection of globals ifSpecialPowers.loadChromeScript
is detected. - Investigate if there's other in-line definitions that could be replaced in similar ways.
- Rename files / improve handling of environments, so that in-line
eslint-env
definitions are no longer required at all.- In a few cases it may make sense to use
/* global ... */
but I'd like to generally avoid that if possible as that would require more maintenance.
- In a few cases it may make sense to use
We should be ending up with a ESLint system where the existing environments are not being used, and it is mainly hidden "behind the scenes".
Reporter | ||
Updated•1 year ago
|
Blocks: eslint-flat
You need to log in
before you can comment on or make changes to this bug.
Description
•