
Highlights
This release contains the following breaking changes:
- Making RuleTester checks stricter.
- Plugins are now loaded relative to the configs that reference them.
- Use the current working directory as base path when using
--config.
It also adds support for the following new language features:
- Core rules now support
globalThis.
Installing
Since this is a pre-release version, you will not automatically be upgraded by npm. You must specify the next tag when installing:
npm i eslint@next --save-dev
You can also specify the version directly:
npm i eslint@7.0.0-alpha.3 --save-dev
Migration Guide
As there are a lot of changes, we’ve created a migration guide describing the changes in great detail along with the steps you should take to address them. We expect that most users should be able to upgrade without any build changes, but the migration guide should be a useful resource if you encounter problems.
Breaking Changes
78c8cdaBreaking: RuleTester Improvements (refs eslint/rfcs#25) (#12955) (Milos Djermanovic)185982dBreaking: improve plugin resolving (refs eslint/rfcs#47) (#12922) (Toru Nagashima)48b122fBreaking: change relative paths with --config (refs eslint/rfcs#37) (#12887) (Toru Nagashima)
Enhancements
e0f1b6cUpdate: stricter array index check in no-magic-numbers (fixes #12845) (#12851) (Milos Djermanovic)362713cUpdate: Improve report location for template-curly-spacing (#12813) (Milos Djermanovic)105384cUpdate: report operator location in operator-linebreak (refs #12334) (#13102) (Milos Djermanovic)081e240Update: support globalThis in no-implied-eval (fixes #12670) (#13105) (YeonJuan)a1370abUpdate: Report constructor calls in no-obj-calls (#12909) (Milos Djermanovic)085979fUpdate: consider env in no-implied-eval (fixes #12733) (#12757) (YeonJuan)e90b29bUpdate: Allow testing Suggestions with data in RuleTester (fixes #12606) (#12635) (Milos Djermanovic)183e300Update: support globalThis (refs #12670) (#12774) (YeonJuan)1299705Update: acorn version (#13016) (Idan Avrahami)
Bug Fixes
29f32dbFix: Change error message logic for implicit file ignore (fixes #12873) (#12878) (Scott Hardin)eb1a43cFix: require-await ignore async generators (fixes #12459) (#13048) (Anix)920465bFix: getNameLocationInGlobalDirectiveComment end location (refs #12334) (#13086) (Milos Djermanovic)ae14a02Fix: add end location to report in no-extra-bind (refs #12334) (#13083) (Milos Djermanovic)0c20bc0Fix: check assignment property target in camelcase (fixes #13025) (#13027) (YeonJuan)8d50a7dFix: add end location to report in no-prototype-builtins (refs #12334) (#13087) (Milos Djermanovic)3e4e7f8Fix: incorrect logic for required parens in no-extra-boolean-cast fixer (#13061) (Milos Djermanovic)aef9488Fix: allow references to external globals in id-blacklist (fixes #12567) (#12987) (Milos Djermanovic)4955c50Fix: remove type arguments in prefer-object-spread (fixes #13058) (#13063) (Milos Djermanovic)dbe357dFix: check template literal in prefer-numeric-literals (fixes #13045) (#13046) (YeonJuan)2260611Fix: added async in allow method in no-empty-function (fixes #12768) (#13036) (Anix)7224eeeFix: no-plusplus allow comma operands in for afterthought (fixes #13005) (#13024) (Milos Djermanovic)7598cf8Fix: Newline before eof when creating config via --init (#12952) (Andreas Lind)0243549Fix: camelcase false positive with computed property (fixes #13022) (#13023) (Milos Djermanovic)6cef0d5Fix: Check division operator in astUtils.canTokensBeAdjacent (#12879) (Milos Djermanovic)
Documentation
6c069f9Docs: Add comments to code block in example (#13089) (Kibeom Kwon)ee1f053Docs: Fix typo (#13092) (Max Coplan)76324acDocs: Add further reading to rule (#13084) (Max Coplan)3f7c9bfDocs: clarify variables option in no-use-before-define (fixes #12986) (#13017) (Anix)9ac5b9eDocs: Clarify node_modules is ignored by default (fixes #13006) (#13054) (Mika Kuijpers)0de91f3Docs: removed correct code from incorrect eg (#13060) (Anix)af7af9dDocs: Update governance (#13055) (Nicholas C. Zakas)79ac6cdDocs: added less confusing explanation for func-style (fixes #12900) (#13004) (Anix)
Dependency Upgrades
2111c52Upgrade: esquery@1.2.0 (#13076) (Milos Djermanovic)95613d4Upgrade: espree@6.2.1 (#13026) (Kai Cataldo)

