eslint-plugin-remeda

raw JSON →
2.1.0 verified Sat Apr 25 auth: no javascript

An ESLint plugin that provides lint rules for the Remeda functional programming utility library. The current stable version is 2.1.0, released on 2025-11-02, with a fast cadence of minor releases every few months. It requires ESLint >=9.0.0 and Node >=22. Key differentiators: it is the only dedicated ESLint plugin for Remeda, offers 14 rules (most auto-fixable), includes a recommended configuration, and is written in TypeScript with type definitions included. It was originally forked from eslint-plugin-lodash-f and adapted for Remeda's API.

error ESLint couldn't find the plugin 'eslint-plugin-remeda'.
cause Plugin not installed or not properly registered in ESLint config.
fix
Run 'pnpm add -D eslint-plugin-remeda' and ensure the import is correct in the flat config.
error Error: Rule 'remeda/prefer-constant' is not defined.
cause Plugin not registered in the 'plugins' section of flat config.
fix
Add 'remeda: remedaPlugin' to plugins object.
error Error: Failed to load config 'remeda/recommended' from 'eslint-plugin-remeda'.
cause Using eslintrc format which is not supported.
fix
Migrate to flat config (eslint.config.js).
error node:internal/modules/cjs/loader: ... Error: Cannot find module 'eslint-plugin-remeda'
cause CommonJS require not supported in plugin v1+.
fix
Use dynamic import or switch to ESM.
breaking Requires ESLint >=9.0.0. Not compatible with legacy eslintrc format.
fix Use flat config (eslint.config.js) and ESLint v9+. If using eslintrc, stay on older versions or migrate.
breaking Node.js >=22 required as of v2.0.0.
fix Upgrade Node.js to version 22 or later.
deprecated Rule 'prefer-is-nil' was removed in v1.5.0.
fix Use 'prefer-is-nullish' instead.
gotcha All rules are off by default unless using the recommended configuration.
fix Apply configs.recommended or manually enable desired rules.
gotcha Plugin expects remeda to be installed, but it is not a peer dependency.
fix Install remeda separately: pnpm add remeda.
npm install eslint-plugin-remeda
yarn add eslint-plugin-remeda
pnpm add eslint-plugin-remeda

Sets up the plugin in an ESLint flat config, applies recommended rules, and overrides two specific rules.

// eslint.config.js (flat config)
import remedaPlugin from 'eslint-plugin-remeda';

export default [
  {
    plugins: {
      remeda: remedaPlugin,
    },
    rules: {
      ...remedaPlugin.configs.recommended.rules,
      // Override or add additional rules
      'remeda/prefer-constant': 'warn',
      'remeda/prefer-filter': 'error',
      'remeda/collection-method-value': 'error',
    },
  },
];