Configuration for rule "no-labels" is invalid
See original GitHub issueHello,
I created a new .eslintrc
and copy/paste in it:
{
"extends": "airbnb"
}
Then I’ve installed packages as specified in airbnb doc.
When I run eslint, I have the error:
D:\_PROJECTPATH_>gulp eslint
[12:37:06] Using gulpfile D:\_PROJECTPATH_\gulpfile.js
[12:37:06] Starting 'eslint'...
D:\_PROJECTPATH_\node_modules\gulp-eslint\node_modules\eslint\lib\config\config-file.js:332
throw e;
^
Error: D:\_PROJECTPATH_\node_modules\eslint-config-airbnb\rules\best-practices.js:
Configuration for rule "no-labels" is invalid:
Value "2,[object Object]" has more items than allowed.
Referenced from: D:\_PROJECTPATH_\node_modules\eslint-config-airbnb\legacy.js
Referenced from: D:\_PROJECTPATH_\node_modules\eslint-config-airbnb\base.js
Referenced from: airbnb
Referenced from: D:\_PROJECTPATH_\.eslintrc
at validateRuleOptions (D:\_PROJECTPATH_\node_modules\gulp-eslint\node_modules\eslint\lib\config\config-validator.js:102:15)
at D:\_PROJECTPATH_\node_modules\gulp-eslint\node_modules\eslint\lib\config\config-validator.js:148:13
at Array.forEach (native)
at Object.validate (D:\_PROJECTPATH_\node_modules\gulp-eslint\node_modules\eslint\lib\config\config-validator.js:147:35)
at load (D:\_PROJECTPATH_\node_modules\gulp-eslint\node_modules\eslint\lib\config\config-file.js:390:19)
at D:\_PROJECTPATH_\node_modules\gulp-eslint\node_modules\eslint\lib\config\config-file.js:326:36
at Array.reduceRight (native)
at applyExtends (D:\_PROJECTPATH_\node_modules\gulp-eslint\node_modules\eslint\lib\config\config-file.js:309:28)
at load (D:\_PROJECTPATH_\node_modules\gulp-eslint\node_modules\eslint\lib\config\config-file.js:395:22)
at D:\_PROJECTPATH_\node_modules\gulp-eslint\node_modules\eslint\lib\config\config-file.js:326:36
Someone else has the same problem here
Issue Analytics
- State:
- Created 8 years ago
- Comments:8
Top Results From Across the Web
Configuration for rule "no-labels" is invalid · Issue #23 - GitHub
I use eslint 2.0.0 and eslint-config-standard 5.1.0. I still get: Error: standard: Configuration for rule "no-labels" is invalid: Value "2,[ ...
Read more >no-labels - ESLint - Pluggable JavaScript Linter
A pluggable and configurable linter tool for identifying and reporting on patterns in JavaScript. Maintain your code quality with ease.
Read more >Eslint error, configuration for rule "import/no-cycle" is invalid
I changed the node_modules/eslint-config-airbnb-base/rules/imports.js "∞" to an integer to continue debugging. Next run showed this error, ...
Read more >Setting the record straight about No Labels | The Hill
In June, No Labels released a roadmap to force through real rules reforms in the next Congress with our Speaker Project reform booklet....
Read more >No Labels
A national movement of people who believe in America and in bringing our leaders together to solve our toughest problems.
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
@ljharb yes, I have different versions — 2.7.0 locally, and 2.5.3 globally, but also I had gulp-eslint 1.0.0 which I updated to 2.0.0 and then error disappeared
@andreyvolokitin do you have eslint 2.7.0 installed locally or globally? Does
npm ls -g --depth=0
include a version of eslint that’s different thannpm ls --depth=0
?