Open-Awesome
CategoriesAlternativesStacksSelf-HostedExplore
Open-Awesome

© 2026 Open-Awesome. Curated for the developer elite.

TermsPrivacyAboutGitHubRSS
  1. Home
  2. ESLint
  3. N

N

MITJavaScriptv18.5.0

An ESLint plugin providing additional rules for Node.js-specific code patterns and best practices.

GitHubGitHub
347 stars67 forks0 contributors

What is N?

eslint-plugin-n is an ESLint plugin that provides additional linting rules specifically for Node.js code. It helps developers catch common Node.js-specific errors, enforce best practices, and ensure code compatibility with targeted Node.js versions. The plugin is a community-maintained fork of the original eslint-plugin-node, which is no longer actively maintained.

Target Audience

Node.js developers and teams who want to improve code quality, maintainability, and compatibility in their Node.js projects using ESLint for static analysis.

Value Proposition

Developers choose eslint-plugin-n because it offers a comprehensive, actively maintained set of Node.js-specific linting rules that seamlessly integrate with ESLint. Its ability to automatically infer supported Node.js versions from project configuration and its focus on catching real-world Node.js pitfalls make it a valuable tool for ensuring robust server-side JavaScript.

Overview

Additional ESLint rules for Node.js

Use Cases

Best For

  • Enforcing consistent use of CommonJS vs. ES module syntax in Node.js projects
  • Detecting usage of deprecated or unsupported Node.js APIs before runtime errors occur
  • Validating that imported modules exist and are correctly specified
  • Ensuring proper error handling patterns in Node.js callback-based code
  • Linting projects that target specific Node.js versions or need cross-version compatibility
  • Automatically fixing common Node.js code style issues like export patterns and import protocols

Not Ideal For

  • Front-end web applications with no Node.js server-side code or build steps
  • Projects using TypeScript exclusively with @typescript-eslint and no need for additional Node.js-specific linting
  • Environments where ESLint is not adopted, such as teams relying on JSHint or other alternative linters
  • Legacy codebases still on the original eslint-plugin-node without plans to migrate, due to potential configuration differences

Pros & Cons

Pros

Comprehensive Node.js Rules

Offers a wide range of rules for API validation, module systems, and best practices, including detecting deprecated APIs and unsupported features based on engine versions from package.json.

Active Community Maintenance

As a fork of the unmaintained eslint-plugin-node, it is actively updated with clear version support tables for Node.js and ESLint, ensuring long-term viability.

Automatic Version Inference

Intelligently infers supported Node.js versions from the package.json engines field or ESLint settings, allowing rules to adapt dynamically to project targets.

Fixable Rules Support

Includes several rules with ESLint's --fix option, such as enforcing consistent export styles and adding the node: protocol to imports, reducing manual refactoring.

Cons

Deprecated Rules Clutter

Contains deprecated rules like no-hide-core-modules and shebang, which can confuse users and require extra effort to avoid or migrate from.

Configuration Complexity

Requires nuanced setup for mixed CommonJS and ES modules, with separate configs like flat/mixed-esm-and-cjs, adding overhead compared to simpler linting plugins.

Node.js-Exclusive Scope

Limited to Node.js environments, making it irrelevant for projects without Node.js code, such as pure browser-based or other runtime JavaScript applications.

Frequently Asked Questions

Quick Stats

Stars347
Forks67
Contributors0
Open Issues26
Last commit5 days ago
CreatedSince 2017

Tags

#commonjs#es-modules#nodejs#code-quality#node#best-practices#eslint-plugin#javascript#eslint#linting#static-analysis

Built With

J
JavaScript
E
ESLint

Included in

ESLint4.7k
Auto-fetched 7 hours ago

Related Projects

BabelBabel

🐠 Babel is a compiler for writing next generation JavaScript.

Stars44,044
Forks5,955
Last commit11 hours ago
FlowFlow

Flow type linting rules for ESLint.

Stars1,065
Forks150
Last commit2 years ago
Flow ErrorsFlow Errors

Run Flow as an ESLint plugin

Stars403
Forks23
Last commit4 years ago
MDXMDX

ESLint Parser/Plugin for MDX

Stars304
Forks35
Last commit2 days ago
Community-curated · Updated weekly · 100% open source

Found a gem we're missing?

Open-Awesome is built by the community, for the community. Submit a project, suggest an awesome list, or help improve the catalog on GitHub.

Submit a projectStar on GitHub