eslint-plugin-import
eslint-plugin-import copied to clipboard
ESLint plugin with rules that help validate proper imports.
A new rule that allows you to ban the creation of `export {} from '...'`. This will help enforce a policy to not create barrel files, which are `index.js` /...
Node.js can do this: ```js // in package foo, in test script: import foo from "foo"; // import itself for test! ``` It seems import/no-unresolved can't handle this.
Hey, Is there any benchmark for the new SCC algorithm? In a project I am maintaining, 2x more time is used compared with 2.27.5. it has 544 files project(in monorepo)....
I cannot get it working with any subpath imports, e.g. **some-file.tsx**: ```ts import { item } from 'package/subpath' ``` leads to an error: ``` ESLint: Unable to resolve path to...
Draft version of the new rule proposed at #2390. This new rule allows for changing between inline type imports (type modifiers introduced in TS 4.5) and separate type import statements...
Hi, I'm not sure if the current behavior is intended or not, so I want to start a discussion. ### Simple setup #### Directory ``` src/ ├── package.json ├── node_modules/...
After upgrading from 2.29.1 to 2.30.0 we got some `not found` errors from `import/named` rule ``` import Select, { ClearIndicatorProps, GroupBase, OptionProps, Props, createFilter } from 'react-select'; Error: 2:18 error...
Given the following rule config: ```js module.exports.rules = { 'import/order': [ 'error', { alphabetize: { order: 'asc', caseInsensitive: true }, groups: ['builtin', 'external', 'internal', ['parent', 'sibling', 'index'], 'object'], 'newlines-between': 'always',...
In order to support more complex use-cases, it would be really nice to be able to exclude parts of the target path. Suggested config: ```js zones: [ { target: './common',...
In 2.30.0 the following code gives a lot of warnings and suggests to import `string`, `number`, etc. instead of using the properties from the default import z.  In this...