Registry / testing / eslint-config-import

eslint-config-import

JSON →
library0.13.0jsnpmunverified

Pre-fabricated ESLint shareable configs for eslint-plugin-import. Current stable version is 0.13.0, but the plugin itself is now at v2.32.0. This package provides three configs: 'import' (basic rules), 'import/warnings' (common mistakes), and 'import/es7-jsx' (ES7/JSX). It is a sibling package that depends on eslint-plugin-import 0.13.x. Note that the plugin has evolved significantly since then; usage with modern ESLint and TypeScript is best handled via the plugin's built-in configs or flat config. Rarely updated; consider using eslint-plugin-import directly.

npm install eslint-config-import
INSTALL
IMPORT
SIG · ESLINT-CONFIG-IMPO
E
eslint-config-import
testingjavascriptv0.13.0
Install
Import
Disk
Pass rate
0/ 6
Env Coverage0 / 6
glibc
1822
musl
1822
Install & Compatibility
Where this runs
tested against v? · npm install
Install × environment matrix
Each cell = how many times install + import succeeded across repeated harness runs. Partial = flaky.
glibc = Debian/Ubuntu slim · musl = Alpine Linux
musl
node 18226 runs
build_error
glibc
node 18226 runs
build_error
Code
Verified usage

Verified import paths — ran on the pinned version, not inferred.

config
module.exports = { extends: ['eslint-config-import'] };
module.exports = { extends: ['import'] };
The npm package name is 'eslint-config-import', but when using extends you can omit the 'eslint-config-' prefix. However, for clarity, include the full name.
warnings config
module.exports = { extends: ['eslint-config-import/warnings'] };
module.exports = { extends: ['import/warnings'] };
Similarly, the 'warnings' sub-config can be referenced with the scoped name.
es7-jsx config
module.exports = { extends: ['eslint-config-import/es7-jsx'] };
module.exports = { extends: ['import/es7-jsx'] };
The 'es7-jsx' sub-config includes parser settings for stage 1 ES7 and JSX.

This shows how to use the 'warnings' config in ESLint. Note the peer dependency version constraint.

// .eslintrc.js module.exports = { extends: ['eslint-config-import/warnings'], rules: { // additional rules } }; // Ensure eslint-plugin-import is installed (peer dependency) // npm install --save-dev eslint-plugin-import@0.13.x
Debug
Known issues
deprecatedThe 'eslint-config-import' package is outdated. Consider using the built-in config from eslint-plugin-import directly.
fix
Remove 'eslint-config-import' from extends and instead use 'plugin:import/recommended' or 'plugin:import/errors' from eslint-plugin-import.
affects: >=0.0.0
gotchaThe recommended config 'import' may conflict with other configs that set parser options.
fix
If using the 'es7-jsx' config, ensure no other config overrides parserOptions.sourceType or ecmaFeatures.jsx.
affects: >=0.0.0
breakingeslint-plugin-import v2.x is not compatible with eslint-config-import v0.13.x.
fix
Downgrade eslint-plugin-import to 0.13.x or use eslint-plugin-import's built-in configs instead.
affects: >=2.0.0
gotchaThe 'es7-jsx' config sets parser: 'babel-eslint' which may be outdated; ESLint v9+ deprecated babel-eslint in favor of @babel/eslint-parser.
fix
Use @babel/eslint-parser directly in your ESLint config, or use a more modern config.
affects: >=9.0.0
Errors
Common errors & fixes
ESLint: Configuration for rule 'import/no-unresolved' is invalid
The config tries to apply rules that are not available in the installed version of eslint-plugin-import.
fix
Ensure eslint-plugin-import version matches the expected peer dependency (0.13.x) or upgrade to a newer config.
Cannot find module 'eslint-plugin-import'
The peer dependency eslint-plugin-import is not installed.
fix
Run: npm install --save-dev eslint-plugin-import@0.13.x
Parsing error: The keyword 'import' is reserved
ESLint parser is not set to support ES modules; the 'import' config assumes a modern parser.
fix
Use a config that sets parserOptions.sourceType: 'module', such as 'eslint-config-import/es7-jsx' or configure your own parserOptions.
Upgrade
Version history
0.13.0latest on npm
Audit
Dependencies
eslint-plugin-importrequiredpeer dependency required for configs to work
Agent activity
1 hits · last 30 days
node
1
Resources