ESLint Config Recommended

raw JSON →
4.1.0 verified Sat Apr 25 auth: no javascript maintenance

A pluggable ESLint configuration pack for ES.Next (ES2015+), Node.js, and React Native. Version 4.1.0 supports ESLint 6.x. Provides pre-defined configs (esnext, node, react-native) with optional style-guide variants. Unlike many single-purpose configs, this package combines multiple environments and can be extended/overridden per rule. Allows granular installation of individual configs (eslint-config-esnext, eslint-config-node, eslint-config-react-native). Last release appears stale; check for newer versions or consider modern alternatives like eslint-config-airbnb or eslint-config-standard.

error Configuration for rule "no-unused-vars" is invalid
cause The rule options may be incompatible with your config version.
fix
Check rule options in the official ESLint documentation and adjust accordingly.
error Cannot find module 'eslint-config-recommended'
cause Package not installed or not in node_modules.
fix
Run npm install --save-dev eslint-config-recommended.
deprecated ESLint v6 is end-of-life; config may not support newer ESLint versions.
fix Consider migrating to a actively maintained config like eslint-config-airbnb or eslint-config-standard.
gotcha Config files must use 'recommended/' prefix in extends array; otherwise ESLint looks for separate packages.
fix Use extends: ['recommended/esnext'] instead of extends: ['esnext'].
gotcha Configs are opinionated and enable many rules; may conflict with your codebase.
fix Override specific rules in your .eslintrc to disable or adjust.
npm install eslint-config-recommended
yarn add eslint-config-recommended
pnpm add eslint-config-recommended

Shows how to set up ESLint with the recommended/esnext config and override a rule.

// .eslintrc.json
{
  "extends": ["recommended/esnext", "recommended/esnext/style-guide"],
  "rules": {
    "no-console": "off"
  }
}

// install
npm install --save-dev eslint-config-recommended eslint