Registry / testing / eslint-plugin-react-dom

eslint-plugin-react-dom

JSON →
library4.2.3jsnpmunverified

An ESLint plugin for React DOM-specific linting rules, part of the @eslint-react monorepo. Current stable version is 4.2.3, requiring Node >=22.0.0 and ESLint ^10.0.0. It provides rules for DOM-related best practices in React applications. The package ships with TypeScript types. Note that the latest releases are in v5 beta (5.5.1-beta.0) with breaking changes on the v5 track. Key differentiator: focused solely on DOM rules, unlike broader React ESLint plugins. Release cadence is active with frequent beta updates.

testing
Install & Compatibility
Where this runs
tested against v? · npm install
Install × environment matrix
Each cell = how many times install + import succeeded across repeated harness runs. Partial = flaky.
glibc = Debian/Ubuntu slim · musl = Alpine Linux
musl
node 18226 runs
build_error
glibc
node 18226 runs
build_error
Code
Verified usage

Verified import paths — ran on the pinned version, not inferred.

ESM only since v4; require() fails in Node 22+.

import plugin from 'eslint-plugin-react-dom'

Access individual rule implementations as an object.

import { rules } from 'eslint-plugin-react-dom'

configs is a named export, not a default export from a subpath.

import { configs } from 'eslint-plugin-react-dom'

Configures the plugin with two DOM-specific rules in an ESLint flat config file.

// eslint.config.js import pluginReactDom from 'eslint-plugin-react-dom'; export default [ { plugins: { 'react-dom': pluginReactDom, }, rules: { 'react-dom/no-dangerously-set-innerhtml': 'error', 'react-dom/no-missing-iframe-sandbox': 'warn', }, }, ];
Debug
Known footguns
breakingNode >=22.0.0 required; plugin will not load on older versions.
breakingESLint ^10.0.0 required; flat config only.
breakingESM-only package; require() will throw ERR_REQUIRE_ESM.
deprecatedv5 series is in beta with breaking changes; v4 is still stable.
gotchaRules may require type information; not all work without TypeScript.
Upgrade
Version history

Breaking-change detection hasn't run for this library yet.

Audit
Security & dependencies

CVE tracking and dependency tree are planned for a later release.

Agent activity
5 hits · last 30 days
ahrefsbot
4
script
1
Resources