question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

First line is always an error after upgrading eslint to 3.4.0

See original GitHub issue

Error : Rule ‘space-after-keywords’ are removed and replaced by keyword spacing.

this is my eslintrc.json

{
  "rules": {
    "dot-notation": 2,
    "eqeqeq": [2, "smart"],
    "no-caller": 2,
    "no-lone-blocks": 2,
    "no-loop-func": 2,
    "no-multi-spaces": 2,
    "no-return-assign": 2,
    "no-script-url": 2,
    "no-self-compare": 2,
    "no-sequences": 2,
    "no-throw-literal": 2,
    "no-with": 2,
    "radix": [2, "as-needed"],
    "wrap-iife": [2, "outside"],
    "yoda": 2,
    "no-extra-bind": 2,
    "no-shadow-restricted-names": 2,
    "array-bracket-spacing": [2, "never"],
    "block-spacing": [2, "always"],
    "brace-style": [2, "1tbs", {"allowSingleLine": true}],
    "camelcase": [2, {"properties": "never"}],
    "comma-spacing": [2, {"before": false, "after": true}],
    "comma-style": [2, "last"],
    "computed-property-spacing": [2, "never"],
    "consistent-this": [2, "self"],
    "id-length": [2, {"min": 1, "max": 32, "properties": "never"}],
    "indent": [2, 3, {"SwitchCase": 1, "VariableDeclarator": {"var": 3, "let": 3, "const": 3}}],
    "linebreak-style": [2, "unix"],
    "lines-around-comment": [2, {
        "beforeBlockComment": true,
        "beforeLineComment": true,
        "allowBlockStart": true,
        "allowBlockEnd": true,
        "allowObjectStart": true,
        "allowObjectEnd": true,
        "allowArrayStart": true,
        "allowArrayEnd": true
        }
    ],
    "new-cap": [2, {"capIsNew": false}],
    "new-parens": 2,
    "no-array-constructor": 2,
    "no-lonely-if": 2,
    "no-mixed-spaces-and-tabs": 2,
    "no-spaced-func": 2,
    "no-trailing-spaces": [2, {"skipBlankLines": true}],
    "use-isnan": 2,
    "no-unneeded-ternary": [2, {"defaultAssignment": false}],
    "operator-assignment": [2, "always"],
    "quote-props": [2, "consistent"],
    "quotes": [2, "single", "avoid-escape"],
    "semi-spacing": [2, {"before": false, "after": true}],
    "semi": [2, "always"],
    "space-after-keywords": [2, "always"],
    "space-before-blocks": [2, "always"],
    "space-before-function-paren": [2, "never"],
    "space-before-keywords": [2, "always"],
    "space-infix-ops": [2, {"int32Hint": false}],
    "space-return-throw-case": 2,
    "space-unary-ops": [2, {"words": true, "nonwords": false}],
    "spaced-comment": [2, "always"],
    "wrap-regex": 2,
    "constructor-super": 2,
    "no-arrow-condition": 2,
    "no-const-assign": 2,
    "no-dupe-class-members": 2,
    "no-this-before-super": 2,
    "prefer-spread": 2,
    "space-after-keywords": 0
  },
  "env": {
    "browser": true,
    "node": true,
    "mocha": true,
    "meteor": true,
    "es6": true
  },
  "ecmaFeatures": {
    "modules": true,
    "jsx": true
  }
}

What version of ESLint are you using?

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

Please show your full configuration:

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

What did you expect to happen?

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

Issue Analytics

  • State:closed
  • Created 7 years ago
  • Comments:6 (4 by maintainers)

github_iconTop GitHub Comments

1reaction
kaicataldocommented, Aug 29, 2016

Hey @hadijaveed - as the error message says, space-after-keywords was removed in ESLint v2.0 and replaced with keyword-spacing.

In the future, if you wouldn’t mind filling out the questions, they help us out a lot. Thanks!

0reactions
nzakascommented, Sep 1, 2016

Closing as resolved

Read more comments on GitHub >

github_iconTop Results From Across the Web

My create-react-app is failing to compile due to ESLint error
1. Delete package-lock.json (not package.json!) and/or yarn.lock in your project folder. 2. Delete node_modules in your project folder. 3.
Read more >
Rules - ESLint - Pluggable JavaScript Linter
These rules relate to possible logic errors in code: ... Enforce consistent line breaks after opening and before closing braces. Categories: ✓ Extends....
Read more >
eslint/eslint - Gitter
Currently I get eslint errors in Atom and the console for .js files but I don't see any linting errors for .vue files,...
Read more >
eslint | Yarn - Package Manager
ESLint is a tool for identifying and reporting on patterns found in ECMAScript/JavaScript code. In many ways, it is similar to JSLint and...
Read more >
eslint-plugin-prettier - npm
Please read Integrating with linters before installing. Sample. error: Insert `,` (prettier/prettier) ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found