{"id":19543,"library":"eslint-config-mx","title":"MX ESLint Config","description":"eslint-config-mx version 4.0.0 is a shareable ESLint configuration package from MX Technologies. It provides a set of predefined linting rules for JavaScript and React projects, leveraging @babel/eslint-parser for Babel support and including plugins for React and React Hooks. It is distributed via npm, follows semantic versioning, and is designed for simple integration via ESLint's extends feature. Compared to alternatives like eslint-config-airbnb, it focuses on MX's internal best practices and is opinionated but lightweight, with peer dependencies on eslint-plugin-react, @babel/eslint-parser, and eslint-plugin-react-hooks.","status":"active","version":"4.0.0","language":"javascript","source_language":"en","source_url":"https://github.com/mxenabled/eslint-config-mx","tags":["javascript","eslint","eslintconfig"],"install":[{"cmd":"npm install eslint-config-mx","lang":"bash","label":"npm"},{"cmd":"yarn add eslint-config-mx","lang":"bash","label":"yarn"},{"cmd":"pnpm add eslint-config-mx","lang":"bash","label":"pnpm"}],"dependencies":[{"reason":"Required peer dependency for React linting rules","package":"eslint-plugin-react","optional":false},{"reason":"Required peer dependency for parsing Babel-transpiled code","package":"@babel/eslint-parser","optional":false},{"reason":"Required peer dependency for React Hooks linting rules","package":"eslint-plugin-react-hooks","optional":false}],"imports":[{"note":"This is a shareable config, not a module to import directly. Use the string 'mx' in the extends field.","wrong":"import config from 'eslint-config-mx'","symbol":"eslint-config-mx","correct":"In .eslintrc: { \"extends\": \"mx\" }"},{"note":"Can be used in package.json eslintConfig field; do not require it.","wrong":"require('eslint-config-mx')","symbol":"eslintConfig-mx","correct":"In package.json: { \"eslintConfig\": { \"extends\": \"mx\" } }"},{"note":"No default export; use extends string in config object.","wrong":"const config = require('eslint-config-mx').default","symbol":"default","correct":"In .eslintrc.js: module.exports = { extends: ['mx'] }"}],"quickstart":{"code":"// .eslintrc.json\n{\n  \"extends\": \"mx\",\n  \"rules\": {\n    \"semi\": [\"error\", \"always\"],\n    \"no-console\": \"warn\"\n  }\n}\n\n// or .eslintrc.js\nmodule.exports = {\n  extends: ['mx'],\n  rules: {\n    semi: ['error', 'always'],\n    'no-console': 'warn',\n  },\n};\n\n// Ensure peerDependencies are installed:\n// npm install --save-dev eslint-plugin-react @babel/eslint-parser eslint-plugin-react-hooks","lang":"javascript","description":"Shows how to extend the MX ESLint config in different ESLint config formats and override rules."},"warnings":[{"fix":"This config uses legacy config format. For ESLint v9, use eslint.config.js or wait for a flat config version of eslint-config-mx.","message":"ESLint config breaks with ESLint v9 or flat config format","severity":"broken","affected_versions":">=4.0.0"},{"fix":"Install @babel/eslint-parser as a dev dependency: npm install --save-dev @babel/eslint-parser","message":"Peer dependency @babel/eslint-parser is required but may be missing in some setups","severity":"deprecated","affected_versions":">=4.0.0"},{"fix":"Ensure @babel/eslint-parser is configured correctly in your ESLint settings or use a different parser if not using Babel.","message":"The config assumes Babel is used for parsing; projects without Babel may encounter parsing errors","severity":"gotcha","affected_versions":">=4.0.0"},{"fix":"The string should be 'mx', not the full package name, when using the extends field in ESLint config.","message":"The config extends 'mx', not 'eslint-config-mx' in the extends field","severity":"gotcha","affected_versions":">=1.0.0"}],"env_vars":null,"last_verified":"2026-04-25T00:00:00.000Z","next_check":"2026-07-24T00:00:00.000Z","problems":[{"fix":"npm install --save-dev eslint-plugin-react","cause":"Missing peer dependency eslint-plugin-react","error":"Error: Cannot find module 'eslint-plugin-react'"},{"fix":"Change extends to 'mx' (without 'eslint-config-' prefix)","cause":"Using the full package name instead of the shorthand 'mx' in extends","error":"Error: ESLint configuration in .eslintrc.json is invalid: \"extends\": \"eslint-config-mx\""},{"fix":"npm install --save-dev @babel/eslint-parser","cause":"Missing peer dependency @babel/eslint-parser","error":"Error: Could not find parser '@babel/eslint-parser'"},{"fix":"npm install --save-dev eslint-plugin-react-hooks","cause":"Missing eslint-plugin-react-hooks causing rule definition failure","error":"TypeError: Cannot read properties of undefined (reading 'react')"}],"ecosystem":"npm","meta_description":null,"install_score":null,"install_tag":null,"quickstart_score":null,"quickstart_tag":null}