Eslint: Linting failing with `Rule 'space-after-keywords' was removed and replaced by: keyword-spacing`

Created on 16 Mar 2016  路  3Comments  路  Source: eslint/eslint

What version of ESLint are you using?

v2.4.0

What parser (default, Babel-ESLint, etc.) are you using?

Default.

Please show your full configuration:

https://gist.github.com/fnando/04294be4a3ed2efde964

What did you do? Please include the actual source code causing the issue.

Source code available at: https://github.com/fnando/i18n-js-experiment/tree/master/gems/i18n-js

What did you expect to happen?

To lint either succeed or fail based on actual errors, instead of failing with a configuration that is not even present on my .eslintrc files.

What actually happened? Please include the actual, raw output from ESLint.

Linting fails with Rule 'space-after-keywords' was removed and replaced by: keyword-spacing.

archived due to age question

Most helpful comment

@fnando If you want to avoid parent configurations being loaded (for example, you're in a project with an ESLint config file, but you also have an ESLint config file in an ancestor directory outside the project), you should specify root: true in your configuration.

Can you try that and let us know if that fixes your issue?

JSON:

{
    "root": true,
    "rules": {
        "semi": "error"
    }
}

All 3 comments

OMG! eslint loaded a parent configuration even though I specified something with --config. Is this the correct behavior? Should I open a ticket for this if not?

@fnando If you want to avoid parent configurations being loaded (for example, you're in a project with an ESLint config file, but you also have an ESLint config file in an ancestor directory outside the project), you should specify root: true in your configuration.

Can you try that and let us know if that fixes your issue?

JSON:

{
    "root": true,
    "rules": {
        "semi": "error"
    }
}

Awesome. Didn't know about root. That will be my default option from now on. <3

Was this page helpful?
0 / 5 - 0 ratings

Related issues

ronkorving picture ronkorving  路  3Comments

idchlife picture idchlife  路  3Comments

sergeysova picture sergeysova  路  3Comments

qmmr picture qmmr  路  3Comments

lukeapage picture lukeapage  路  3Comments