Skip to content
PluginStats

eslint-plugin-react-you-might-not-need-an-effect weekly downloads statistics

By nickjvandyke · npm · ESLint plugins

ESLint plugin to catch unnecessary React effects for simpler, faster, safer code.

View on npm Stale · Oct 18, 2026

eslint-plugin-react-you-might-not-need-an-effect has 518,642 recorded weekly downloads on npm, a decrease of 12.3% over the past 30 days, ranking #267 of 2,391 tracked listings.

Weekly downloads
518,642
Official API · Oct 18, 2026
7-day growth
-38.2%
-320K weekly downloads
30-day growth
-12.3%
-72.6K weekly downloads
90-day growth
+16.5%
+73.6K weekly downloads
Rank
#267
Among tracked npm listings

About eslint-plugin-react-you-might-not-need-an-effect

ESLint – React – You Might Not Need An Effect

NPM version NPM Downloads

ESLint (and Oxlint) plugin to catch unnecessary useEffects to make your React code easier to follow, faster to run, and less error-prone. Highly recommended for new React developers as you learn its mental model, and might surprise even experienced developers!

  • Actionable fixes: Reports specific anti-patterns, with suggestions and links.
  • Deep analysis: Analyzes state, props, refs, and their upstream sources.
  • Dependency-aware: Considers when an effect runs to determine if its logic is actually redundant.
  • Edge-case obsessed: Focuses on unusual syntax and heuristics to keep the signal-to-noise ratio high.

React's eslint-plugin-react-hooks/set-state-in-effect rule flags synchronous setState calls inside effects, helping prevent unnecessary re-renders. However, unnecessary effects go far beyond this, as I'm sure we've all seen (or written 😅).

📦 Installation

NPM
npm install --save-dev eslint-plugin-react-you-might-not-need-an-effect
Yarn
yarn add -D eslint-plugin-react-you-might-not-need-an-effect

⚙️ Configuration

Flat Config
// eslint.config.js
import reactYouMightNotNeedAnEffect from "eslint-plugin-react-you-might-not-need-an-effect";
import globals from "globals";

export default [
  // Enable every rule as a warning
  reactYouMightNotNeedAnEffect.configs.recommended,
  // Or enable every rule as an error
  reactYouMightNotNeedAnEffect.configs.strict,
  // Or enable only specific rules
  {
    plugins: {
      reactYouMightNotNeedAnEffect,
    },
    rules: {
      "reactYouMightNotNeedAnEffect/no-derived-state": "warn",
    },
    languageOptions: {
      globals: {
        ...globals.browser,
      },
      parserOptions: {
        ecmaFeatures: {
          jsx: true,
        },
      },
    },
  },
];
Legacy Config
// .eslintrc
{
  "extends": [
    // Enable every rule as a warning
    "plugin:react-you-might-not-need-an-effect/legacy-recommended",
    // Or enable every rule as an error
    "plugin:react-you-might-not-need-an-effect/legacy-strict",
  ],
  // Or enable only specific rules
  "plugins": ["react-you-might-not-need-an-effect"],
  "rules": {
    "react-you-might-not-need-an-effect/no-derived-state": "warn",
  },
  "env": {
    "browser": true,
  },
  "parserOptions": {
    "ecmaFeatures": {
      "jsx": true,
    },
  },
}
Oxlint

Use this plugin with Oxlint thanks to their JS plugin support!

// .oxlintrc.json
{
  "jsPlugins": ["eslint-plugin-react-you-might-not-need-an-effect"],
  "rules": {
    "react-you-might-not-need-an-effect/no-derived-state": "warn",
    "react-you-might-not-need-an-effect/no-chain-state-updates": "warn",
    "react-you-might-not-need-an-effect/no-event-handler": "warn",
    "react-you-might-not-need-an-effect/no-adjust-state-on-prop-change": "warn",
    "react-you-might-not-need-an-effect/no-reset-all-state-on-prop-change": "warn",
    "react-you-might-not-need-an-effect/no-pass-live-state-to-parent": "warn",
    "react-you-might-not-need-an-effect/no-pass-data-to-parent": "warn",
    "react-you-might-not-need-an-effect/no-external-store-subscription": "warn",
    "react-you-might-not-need-an-effect/no-initialize-state": "warn",
  },
  "env": {
    "browser": true,
  },
}
Suggested

Enforce these other rules in your codebase for more accurate analysis:

🔎 Rules

See the tests for extensive (in)valid examples for each rule.

no-derived-state

Disallow storing derived state in an effect:

function Form() {
  const [firstName, setFirstName] = useState("Taylor");
  const [lastName, setLastName] = useState("Swift");

  const [fullName, setFullName] = useState("");
  useEffect(() => {
    // ❌ Avoid storing derived state. Instead, compute "fullName" directly during render.
    setFullName(firstName + " " + lastName);
  }, [firstName, lastName]);
}
no-chain-state-updates

Disallow chaining state updates in an effect:

function Game() {
  const [round, setRound] = useState(1);
  const [isGameOver, setIsGameOver] = useState(false);

  useEffect(() => {
    if (round > 10) {
      // ❌ Avoid chaining state changes. When possible, update "isGameOver" along with other relevant state simultaneously.
      setIsGameOver(true);
    }
  }, [round]);
}
no-event-handler

Disallow using state and an effect as an event handler:

function Form() {
  const [dataToSubmit, setDataToSubmit] = useState();…

Description from the npm listing.

  • eslint
  • eslintplugin
  • eslint-plugin
  • react

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-react-you-might-not-need-an-effect weekly downloads on npm, last 90 days: 518,642 weekly downloads as of Oct 18, 2026, +16.5% over 90 days.eslint-plugin-react-you-might-not-need…Weekly downloads on npm · Last 90 days518,642downloads / week+16.5% over 90 days0200K400K600K800K1MJul 20Aug 4Aug 19Sep 3Sep 18Oct 3Oct 18downloads / weekobservedarchived (Internet Archive)no observationsJul 24, 2026 – Oct 18, 2026 · 87 observations · Updated Oc…pluginstats.com
eslint-plugin-react-you-might-not-need-an-effect weekly downloads on npm, last 90 days: 518,642 weekly downloads as of Oct 18, 2026, +16.5% over 90 days.

7/30/90-day growth

eslint-plugin-react-you-might-not-need-an-effect weekly downloads growth on npm: -38.2% over 7 days, -12.3% over 30 days, +16.5% over 90 days.eslint-plugin-react-you-might-not-need…Weekly downloads growth on npm518,642downloads / week now7-day growth-320,020 weekly downloads-38.2%30-day growth-72,625 weekly downloads-12.3%90-day growth+73,643 weekly downloads+16.5%Growth vs. nearest observation to each baseline date · Updated Oct 18, 2026pluginstats.com
eslint-plugin-react-you-might-not-need-an-effect weekly downloads growth on npm: -38.2% over 7 days, -12.3% over 30 days, +16.5% over 90 days.

Ranking history

eslint-plugin-react-you-might-not-need-an-effect npm ranking history: currently #267 (by weekly downloads).eslint-plugin-react-you-might-not-need…npm ranking · by weekly downloads · Last 90 days#267current rank#262#263#264#265#266#267#268#269Jul 23Aug 7Aug 22Sep 6Sep 21Oct 6Oct 21rankOct 18, 2026 – Oct 21, 2026 · 4 observations · Updated Oct 18, 2026pluginstats.com
eslint-plugin-react-you-might-not-need-an-effect npm ranking history: currently #267 (by weekly downloads).

Listing placement

All npm2,389 listings · 120 pages · 1,195 shown · page 14, #7 (overall #267)
All npm: every listing in weekly downloads order

Listing placement

ESLint plugins258 listings · 13 pages · page 3, #16 (overall #56)
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 (122)
Recent weekly downloads observations for eslint-plugin-react-you-might-not-need-an-effect
Date (UTC)Weekly downloadsChange vs. previous
518,642+63.6K
455,059-57.4K
512,420+22.5K
489,886-197K
686,861-194.3K
881,1660
881,166+42.5K
838,662+29.5K
809,196+15K
794,227+32K
762,237+27.5K
734,774+41.2K
693,585-164.2K
857,811—

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-react-you-might-not-need-an-effect. First seen Oct 16, 2026; last successful collection Oct 21, 2026. See the methodology.