Skip to content
PluginStats

eslint-plugin-import-newlines weekly downloads statistics

By SeinopSys · npm · ESLint plugins

ESLint plugin for enforcing newlines in ES6 import statements past a certain number of items

View on npm Fresh · Dec 6, 2026

eslint-plugin-import-newlines has 207,720 recorded weekly downloads on npm, an increase of 18.2% over the past 30 days, ranking #517 of 3,247 tracked listings.

Weekly downloads
207,720
Official API · Dec 5, 2026
7-day growth
+11.4%
+21.3K weekly downloads
30-day growth
+18.2%
+32K weekly downloads
90-day growth
+94.9%
+101.2K weekly downloads
Rank
#517
▲ 4 in 7 days

About eslint-plugin-import-newlines

eslint-plugin-import-newlines npm npm CI

ESLint plugin for enforcing newlines in ES6 import statements past a certain number of items.

There is only one rule in this plugin which will report when there are more than 4 values in a line by default, and if there are less it will report when the import is not on a single line.

Installation

You'll first need to install ESLint:

$ npm i eslint --save-dev

Next, install eslint-plugin-import-newlines:

$ npm install eslint-plugin-import-newlines --save-dev

Note: If you installed ESLint globally (using the -g flag) then you must also install eslint-plugin-import-newlines globally.

ESLint is an optional peer dependency, so if you only use Oxlint you can skip installing it.

Usage

Flat config (ESLint 9+)

Use the bundled recommended preset, which registers the plugin and enables the rule:

// eslint.config.mjs
import importNewlines from 'eslint-plugin-import-newlines';

export default [
  importNewlines.configs.recommended,
];

Or register the plugin yourself to configure the rule:

// eslint.config.mjs
import importNewlines from 'eslint-plugin-import-newlines';

export default [
  {
    plugins: {
      'import-newlines': importNewlines,
    },
    rules: {
      'import-newlines/enforce': ['error', { items: 2, 'max-len': 100 }],
    },
  },
];
Legacy .eslintrc

Add import-newlines to the plugins section of your .eslintrc configuration file.

{
  "plugins": [
    "import-newlines"
  ]
}

Then add the rule in the rules section.

{
  "rules": {
    "import-newlines/enforce": "error"
  }
}
Using with Oxlint

The rule does not depend on ESLint at runtime, so the plugin also works with Oxlint's JS plugins (currently in alpha). Install the plugin (ESLint is not required):

$ npm install eslint-plugin-import-newlines --save-dev

Then add it under jsPlugins in your .oxlintrc.json and enable the rule. The rule options are the same as with ESLint.

{
  "jsPlugins": [
    "eslint-plugin-import-newlines"
  ],
  "rules": {
    "import-newlines/enforce": [
      "error",
      {
        "items": 2,
        "max-len": 100,
        "semi": false
      }
    ]
  }
}

If you use oxlint.config.ts instead, put the same jsPlugins and rules values in defineConfig({ ... }).

Options

The first and most readable way is to use an object which allows you to specify any of the available options, leaving everything that's not specified as the default.

{
"rules": {
  "max-len": [
    "error",
    100
  ],
  "semi": [
    "error",
    "never"
  ],
  "import-newlines/enforce": [
    "error",
    {
      "items": 2,
      "max-len": 100,
      "semi": false
    }
  ]
}
}

Because of its easy expandability this is the only format that will allow you to configure any new options – should they be added – but there is also a shorter syntax that will let you configure just the first two and keep everything else default.

To specify items as 6:

{
"rules": {
  "import-newlines/enforce": [
    "error",
    6
  ]
}
}

To specify items as 4 and max-len as 120:

{
"rules": {
  "max-len": [
    "error",
    120
  ],
  "import-newlines/enforce": [
    "error",
    4,
    120
  ]
}
}
items [number] (default: 4)

Specifies the maximum number of items before the plugin requires breaking up the import to multiple lines. If there are exactly this many or fewer items, then the plugin will make sure the import stays on one line unless it would violate the max-len option. More items than this number will always be split onto multiple lines.

Note that the plugin simply inserts newline characters after each token in the import when splitting, and the fix output never includes leading tabs or spaces. To have consistent indentation, be sure to use the built-in indent rule.

max-len [number] (default: Infinity)

Specifies the maximum length for source code lines in your project. This allows the plugin to prevent quick fixes that would cause your code to violate this limit from being applied. The rule will also automatically split import lines for you should they exceed the limit, which works great as an automatic fix for the ESLint built-in max-len rule (which doesn't have any quick fixes out of the box at the time of writing) for your imports. It's highly recommended you keep this option's value in sync with what you use for the aforementioned rule for best results.

semi [boolean] (default: true)

Indicates whether you want to have semicolons at the end of your imports. This is used in the maximum length calculation for the previous rule, so be sure to set this to false if your code style does not use semicolons at the end of imports otherwise it can lead to some unexpected automatic fixes.

Note that this does not enforce the use of semicolons, use the built-in ESLint semi rule to control that. Setting this to the right value merely aims to ensure that the plugin will not produce conflicting quick fixes.

Also, to preserve backwards compatibility with the existing array-based configuration, this is always set to false when not using the new object syntax to configure the rule.…

Description from the npm listing.

  • eslint
  • eslint-plugin
  • eslintplugin
  • lint
  • import

README badge

Show your rank in a README or on your website. The badge updates automatically.

Charts

Images: 30d · 1y · all time · 1600×900 dark

Adoption over time

eslint-plugin-import-newlines weekly downloads on npm, last 90 days: 207,720 weekly downloads as of Dec 5, 2026, +94.9% over 90 days.eslint-plugin-import-newlinesWeekly downloads on npm · Last 90 days207,720downloads / week+94.9% over 90 days050K100K150K200K250KSep 6Sep 21Oct 6Oct 21Nov 5Nov 20Dec 5downloads / weekobservedarchived (Internet Archive)no observationsSep 7, 2026 – Dec 5, 2026 · 90 observations · Updated Dec …pluginstats.com
eslint-plugin-import-newlines weekly downloads on npm, last 90 days: 207,720 weekly downloads as of Dec 5, 2026, +94.9% over 90 days.

7/30/90-day growth

eslint-plugin-import-newlines weekly downloads growth on npm: +11.4% over 7 days, +18.2% over 30 days, +94.9% over 90 days.eslint-plugin-import-newlinesWeekly downloads growth on npm207,720downloads / week now7-day growth+21,253 weekly downloads+11.4%30-day growth+31,996 weekly downloads+18.2%90-day growth+101,168 weekly downloads+94.9%Growth vs. nearest observation to each baseline date · Updated Dec 5, 2026pluginstats.com
eslint-plugin-import-newlines weekly downloads growth on npm: +11.4% over 7 days, +18.2% over 30 days, +94.9% over 90 days.

Ranking history

eslint-plugin-import-newlines npm ranking history: currently #517 (by weekly downloads).eslint-plugin-import-newlinesnpm ranking · by weekly downloads · Last 90 days#517current rank#490#500#510#520#530#540Sep 7Sep 22Oct 7Oct 22Nov 6Nov 21Dec 6rankOct 18, 2026 – Dec 6, 2026 · 44 observations · Updated Dec 5, 2026pluginstats.com
eslint-plugin-import-newlines npm ranking history: currently #517 (by weekly downloads).

Listing placement

All npm3,247 listings · 163 pages · 1,083 shown · page 26, #17 (overall #517)
All npm: every listing in weekly downloads order

Listing placement

ESLint plugins290 listings · 15 pages · page 6, #18 (overall #118)
ESLint plugins: every listing in weekly downloads order

Filled points are observed values; hollow points come from Internet Archive snapshots of the listing page. Dashed segments span periods with no observations — values between points are not interpolated.

Each band is one page of 20. Weekly downloads on a linear scale. Placement is projected from weekly downloads, so it can differ from the marketplace's own sort order. Hover a dot to see the listing.

Recent observations

Full history (170)
Recent weekly downloads observations for eslint-plugin-import-newlines
Date (UTC)Weekly downloadsChange vs. previous
207,720-2.3K
209,985+7.7K
202,254+4.6K
197,644+3.1K
194,506+8.3K
186,185+1.3K
184,930-1.5K
186,467+1.5K
185,003-8K
193,030-7.6K
200,645-5.5K
206,112-6.5K
212,564-2.8K
215,330—

Similar npm ESLint plugins plugins

All 20 eslint-plugin-import-newlines alternatives

Data source

Weekly downloads (trailing 7 complete days) come from the official npm downloads API. Downloads include CI and mirrors and are not equivalent to installs or users. npm publishes no ratings.

Listing: https://www.npmjs.com/package/eslint-plugin-import-newlines. First seen Oct 16, 2026; last successful collection Dec 6, 2026. See the methodology.