{"id":10415,"library":"react","title":"React","description":"React is a JavaScript library for building user interfaces, currently at version 19.2.5. It focuses on declarative UI development and a component-based architecture. Recent patch releases primarily include stability and security enhancements for React Server Components (RSC), indicating a rapid release cadence for critical updates, alongside updates for its ecosystem tooling like `eslint-plugin-react-hooks`.","status":"active","version":"19.2.5","language":"javascript","source_language":"en","source_url":"https://github.com/facebook/react","tags":["javascript","react"],"install":[{"cmd":"npm install react","lang":"bash","label":"npm"},{"cmd":"yarn add react","lang":"bash","label":"yarn"},{"cmd":"pnpm add react","lang":"bash","label":"pnpm"}],"dependencies":[],"imports":[{"wrong":"const { useState } = require('react')","symbol":"useState","correct":"import { useState } from 'react'"}],"quickstart":{"code":"import React, { useState } from 'react';\nimport ReactDOM from 'react-dom/client';\n\nfunction Counter() {\n  const [count, setCount] = useState(0);\n\n  return (\n    <div>\n      <p>You clicked {count} times</p>\n      <button onClick={() => setCount(count + 1)}>\n        Click me\n      </button>\n    </div>\n  );\n}\n\n// Render the component\nconst root = ReactDOM.createRoot(document.getElementById('root') ?? document.createElement('div'));\nroot.render(<Counter />);","lang":"typescript","description":"A basic functional component demonstrating state management with the `useState` hook and rendered using `createRoot`."},"warnings":[{"fix":"Upgrade `eslint-plugin-react-hooks` to version 7.1.1 or higher. If you still reference the `component-hook-factories` rule, consider removing it as it's now a no-op.","message":"The `eslint-plugin-react-hooks` package in version 7.1.0 accidentally removed the `component-hook-factories` rule, causing ESLint configurations that referenced it to fail. It was re-added as a no-op in 7.1.1.","severity":"breaking","affected_versions":"eslint-plugin-react-hooks@7.1.0"},{"fix":"Stay updated with React patch releases and consult the official React documentation and community for best practices and latest guidance on Server Components. Regularly test RSC-heavy applications.","message":"React Server Components (RSC) are a rapidly evolving area in React 19, with frequent updates focused on security, DoS mitigations, cycle protections, and loop safeguards. Users extensively relying on RSCs should be aware of potential subtle behavioral changes or new edge cases with each patch.","severity":"gotcha","affected_versions":">=19.0.0"}],"env_vars":null,"last_verified":"2026-04-18T00:00:00.000Z","next_check":"2026-07-17T00:00:00.000Z","problems":[{"fix":"Upgrade `eslint-plugin-react-hooks` to version 7.1.1 or later (`npm install eslint-plugin-react-hooks@latest`). If the rule is still in your ESLint config, you can safely remove it as it's now a no-op.","cause":"The `component-hook-factories` rule was temporarily removed from `eslint-plugin-react-hooks` in version 7.1.0.","error":"Configuration for rule 'component-hook-factories' is invalid: The rule 'component-hook-factories' was not found."},{"fix":"Review your Server Component/Function dependencies for circular references. Optimize data fetching and ensure server-side logic has appropriate exit conditions to prevent infinite loops, especially in `use` or `async` contexts.","cause":"React Server Functions or Server Components hitting internal loop/cycle protection mechanisms, often due to circular dependencies or excessive recursive calls mentioned in recent DoS and loop protection updates.","error":"Maximum call stack size exceeded"}],"ecosystem":"npm"}