Comments (4)
@FirelightFlagboy As per typescript-eslint/typescript-eslint#7935 (comment), you can't use '@typescript-eslint/eslint-plugin'
for flat config, there is a different package typescript-eslint
. The new usage is mentioned in this doc
If that still doesn't work for you, can you open an issue in typescript-eslint repo instead?
from eslint.
typescript_plugin.configs.eslint_recommended
Can you check what the value of typescript_plugin.configs.eslint_recommended
is? It could be that @typescript-eslint/eslint-plugin
doesn't export a config named eslint_recommended
, in which case this would be undefined
.
from eslint.
The value of typescript_plugin.configs.eslint_recommended
should be:
"use strict";
module.exports = {
overrides: [
{
files: ['*.ts', '*.tsx', '*.mts', '*.cts'],
rules: {
'constructor-super': 'off', // ts(2335) & ts(2377)
'getter-return': 'off', // ts(2378)
'no-const-assign': 'off', // ts(2588)
'no-dupe-args': 'off', // ts(2300)
'no-dupe-class-members': 'off', // ts(2393) & ts(2300)
'no-dupe-keys': 'off', // ts(1117)
'no-func-assign': 'off', // ts(2630)
'no-import-assign': 'off', // ts(2632) & ts(2540)
'no-new-symbol': 'off', // ts(7009)
'no-obj-calls': 'off', // ts(2349)
'no-redeclare': 'off', // ts(2451)
'no-setter-return': 'off', // ts(2408)
'no-this-before-super': 'off', // ts(2376) & ts(17009)
'no-undef': 'off', // ts(2304) & ts(2552)
'no-unreachable': 'off', // ts(7027)
'no-unsafe-negation': 'off', // ts(2365) & ts(2322) & ts(2358)
'no-var': 'error', // ts transpiles let/const to var, so no need for vars any more
'prefer-const': 'error', // ts provides better types with const
'prefer-rest-params': 'error', // ts provides better types with rest args over arguments
'prefer-spread': 'error', // ts transpiles spread to apply, so no need for manual apply
},
},
],
};
//# sourceMappingURL=eslint-recommended.js.map
I've extract the value from node_modules/@typescript-eslint/eslint-plugin/dist/configs/eslint-recommended.js
from eslint.
It looks like there wasn't enough information for us to know how to help you, so we're closing the issue.
Thanks for your understanding.
from eslint.
Related Issues (20)
- Bug: CLI option `--plugin` cannot load CommonJS plugin in flat config mode HOT 5
- Bug: Migrate away from lodash method packages HOT 6
- Bug: `use-isnan` doesn't report NaN in `indexOf` or `lastIndexOf` when fromIndex is given HOT 5
- Docs: no-return-await deprecation notice leads to a wrong conclusion HOT 24
- Repo: remove internal multiline-comment-style fork/wrapper HOT 1
- Bug: The no-unused-var error cleared by duplicating React Router import
- Change Request: Rule Tester omit specific properties for duplicate test case detection HOT 2
- Change Request: Update strip-ansi to version 7 HOT 1
- Rule Change: no-fallthrough should not permit "falls through" comment when code will not fall through. HOT 4
- Repo: 'documentation' label added and removed quickly on PRs HOT 6
- Bug: `flat config global ignores` should support `git-ignore-alike-syntax` to negate pattern HOT 1
- Rule Change: no-extra-boolean-cast should check final expression in comma operator expressions HOT 5
- Docs: Page does not update when prefers-color-scheme changes HOT 3
- Docs: Option to use system preference for light/dark theme HOT 6
- Scheduled release for March 22nd, 2024 HOT 3
- Bug: cannot override no-unused-vars HOT 4
- Bug: Random error on line 1 column 1 Parsing error: Cannot read properties of undefined (reading 'map') eslint HOT 2
- Bug: Flat config file not found when run with `CWD` outside of source directory HOT 5
- Bug: Flat config doesn't work when `files` refers to a sibling directory. HOT 2
- ESlint error "Switch cases without blocks are disallowed. eslint (no-restricted-syntax)" HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from eslint.