npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

eslint-config-auditor

v3.0.0

Published

Shareable ESLint flat config to help you write clear, efficient JavaScript code.

Readme

Shareable ESLint flat config to help you write clear, efficient JavaScript code.

eslint-config-auditor Version Downloads workflow provenance

Auditor uses sane defaults focused on code readability. The Auditor's philosophy is that good code means easy to understand code.

Along with its own rules, Auditor by default includes widely-used rules from eslint-plugin-import-x, eslint-plugin-promise, and eslint-plugin-n. Auditor lints both browser and Node.js code.

Besides linting standard JavaScript code gracefully, Auditor also has first-class support for React, Jest, and TypeScript. See rules about usage.

Version 2.0.0 targets ESLint 10+ and the flat config format (eslint.config.js). All plugins ship as regular dependencies, so installing this package is all you need. The formatting/stylistic rules are provided through @stylistic/eslint-plugin under the @stylistic/ namespace (ESLint deprecated and is removing these from core).

Installation

npm install --save-dev eslint eslint-config-auditor

Requires ESLint >=10 and Node.js ^20.19.0 || ^22.13.0 || >=24.

Usage

In your eslint.config.js (or eslint.config.mjs):

import auditor from 'eslint-config-auditor';

export default [...auditor];

The default export is the equivalent of the old root config: recommended + finest combined.

CommonJS (eslint.config.cjs) works too:

const auditor = require('eslint-config-auditor').default;

module.exports = [...auditor];

Rules

Auditor has two main rule configs, available as named exports and subpath imports:

  • recommended all the needed rules to write concise JavaScript. Includes all best-practices, Node.js, import, and promise rules. Recommended for most users.
  • finest Auditor at its finest. Strict rules for advanced use cases such as code refactors and open-source software where code changes can break infinite clients. Use it on top of recommended.
// eslint.config.js
import recommended from 'eslint-config-auditor/recommended';
import finest from 'eslint-config-auditor/finest';

export default [...recommended, ...finest];

Formatting (opt-in)

Formatting/stylistic rules are not part of the default config; most projects format with Biome or Prettier, and duplicating that in ESLint just creates noise and conflicts. Opt in with eslint-config-auditor/stylistic only if you want ESLint to own formatting too:

// eslint.config.js: quality rules + ESLint-owned formatting
import auditor from 'eslint-config-auditor';
import stylistic from 'eslint-config-auditor/stylistic';

export default [...auditor, ...stylistic];

The stylistic config (a hardened superset of the Extension.js house style) enforces: 2-space indent, single quotes, double quotes in JSX, 80-column lines, no semicolons, no trailing commas, no spaces inside { }, always-parenthesized arrow params ((x) => x), and blank lines surrounding every if block.

finest additionally caps files at 350 lines of code (blank lines and comments excluded). Files that are routinely large by nature are exempt: config files (*.config.*), type declarations (*.d.ts), generated files (*.generated.*, generated/**), JSON, and test/spec files (*.test.*, *.spec.*, __tests__/**, __spec__/**).

Auditor also offers first-class support for Jest, React, and TypeScript but since these are opinionated tools, you need to activate them manually.

Jest

Uses eslint-plugin-jest (already included).

// eslint.config.js
import auditor from 'eslint-config-auditor';
import jest from 'eslint-config-auditor/jest';

export default [
  ...auditor,
  // Scope Jest rules to your test files
  ...jest.map((config) => ({
    ...config,
    files: ['**/*.test.{js,jsx,ts,tsx}', '**/*.spec.{js,jsx,ts,tsx}'],
  })),
];

Vitest

Uses @vitest/eslint-plugin (already included). Includes the Vitest test globals (describe/it/expect/vi/…), so scope it to your test files just like Jest:

// eslint.config.js
import auditor from 'eslint-config-auditor';
import vitest from 'eslint-config-auditor/vitest';

export default [
  ...auditor,
  // Scope Vitest rules + globals to your test files
  ...vitest.map((config) => ({
    ...config,
    files: ['**/*.test.{js,jsx,ts,tsx}', '**/*.spec.{js,jsx,ts,tsx}'],
  })),
];

React

Uses @eslint-react/eslint-plugin (correctness-focused React rules, including rules-of-hooks and exhaustive-deps) and eslint-plugin-jsx-a11y (already included). Fully ESLint 10 native — it replaces eslint-plugin-react, which calls context.getFilename()/getScope() (removed in ESLint 10) and throws there.

[!NOTE] react and next are ESM-only. @eslint-react/eslint-plugin ships as an ESM-only package, so these two presets are published as ESM-only subpaths. Import them from an ESM config (eslint.config.js in a "type": "module" project, or eslint.config.mjs). Every other preset remains dual ESM + CommonJS.

// eslint.config.mjs
import auditor from 'eslint-config-auditor';
import react from 'eslint-config-auditor/react';

export default [...auditor, ...react];

Next.js

Extends the react preset with the official @next/eslint-plugin-next recommended and core-web-vitals rules (already included). ESM-only, like react.

// eslint.config.mjs
import auditor from 'eslint-config-auditor';
import next from 'eslint-config-auditor/next';

export default [...auditor, ...next];

TypeScript

Uses typescript-eslint and eslint-plugin-import-x (already included). Rules are scoped to **/*.ts/**/*.tsx files and use the project service for type-aware linting, so a tsconfig.json in your project root is all you need.

The base config (recommended/finest) only attaches to JavaScript files, so a TypeScript project must include this config for its .ts/.tsx files to be linted at all. The eslint-config-auditor/ts preset bundles recommended + finest + typescript so you can do it in one import:

// eslint.config.js
import ts from 'eslint-config-auditor/ts';

export default ts;

Or compose it yourself:

// eslint.config.js
import auditor from 'eslint-config-auditor';
import typescript from 'eslint-config-auditor/typescript';

export default [...auditor, ...typescript];

See CONSUMING.md for copy-paste recipes per project type (JS, TS, React, Next.js, Jest, Biome coexistence) and notes on projectService.

All variants can also be pulled from the root entry as named exports:

import { recommended, finest, jest, vitest, react, stylistic, ts, typescript, typescriptChecked } from 'eslint-config-auditor';

Migrating from 0.x

Version 0.x shipped legacy .eslintrc configs for ESLint 8. Version 1.0.0 is a flat-config rewrite for ESLint 9. To migrate:

  1. Upgrade to eslint@>=9 and remove the plugin packages you installed manually for 0.x (eslint-plugin-import, eslint-plugin-promise, eslint-plugin-node, eslint-plugin-jest, eslint-plugin-react, eslint-plugin-react-hooks, eslint-plugin-jsx-a11y, @typescript-eslint/parser, @typescript-eslint/eslint-plugin). They are now bundled as dependencies of this package.

  2. Replace your .eslintrc/.eslintrc.json with an eslint.config.js:

    - { "extends": ["auditor", "auditor/react"] }
    // eslint.config.js
    import auditor from 'eslint-config-auditor';
    import react from 'eslint-config-auditor/react';
    
    export default [...auditor, ...react];
  3. Note these behavioral changes:

    • eslint-plugin-node was replaced by its maintained fork eslint-plugin-n. The node/ rule prefix is preserved, so inline directives like // eslint-disable-next-line node/no-sync keep working. node/shebang is now node/hashbang.
    • @typescript-eslint/parser + @typescript-eslint/eslint-plugin were replaced by typescript-eslint v8. The TypeScript config now uses projectService: true instead of parserOptions.project globs.
    • Environments (env) and parserOptions were translated to languageOptions, with globals provided by the globals package.
    • A few rules were removed or renamed upstream. See MIGRATION.md for the complete old-rule → disposition table.

License

MIT (c) Cezar Augusto.