@testing-library/dom breaking changes
@testing-library/dom 10.0.0 (April 8, 2024) is its newest release with breaking changes, 2 of them. The first: @testing-library/dom 10.0.0 requires Node.js 18.0 or later. Every breaking API change we have recorded in @testing-library/dom on npm: 21 breaking changes in 5 versions. Below, its 5 versions with breaking changes, newest first, removals and renames first, each with its source.
Updated December 4, 2026
On this page
Latest version 10.4.2, released September 13, 2026. Source repository
Its 10.0.0 release requires Node.js 18.0 or later. Node.js end of life dates.
- From 9.0.0 to 10.0.0: 2 breaking changes in 1 version.
- From 8.0.0 to 10.0.0: 12 breaking changes in 4 versions.
@testing-library/dom 10.0.0 breaking changes
- Removed
Node.js 14.x and 16.x are no longer supported, so use Node.js 18.0 or later. github.com - Behavior changed
The aria-query 5.3.0 upgrade changes various roles, so queries that depend on roles may match differently and tests should be checked. github.com
@testing-library/dom 9.0.0 breaking changes
- Removed
Node.js 12.x is no longer supported. Users on Node.js 12 must upgrade to Node.js 14 or later. github.com - Removed
ByRoleOptions.collapseWhitespace
The collapseWhitespace option is no longer supported by ByRole queries. Remove it from calls. npmjs.com - Removed
ByRoleOptions.exact
The exact option is no longer supported by ByRole queries. Remove it from calls. npmjs.com - Removed
ByRoleOptions.normalizer
The normalizer option is no longer supported by ByRole queries. Remove it from calls. npmjs.com - Removed
ByRoleOptions.trim
The trim option is no longer supported by ByRole queries. Remove it from calls. npmjs.com - Signature changed
ByRole
The role argument of ByRole must now be a string. Other values no longer work. github.com - Signature changed
ByRoleMatcher
Was type ByRoleMatcher = ARIARole | MatcherFunction | {}; now type ByRoleMatcher = ARIARole | (string & {}). npmjs.com - Signature changed
ByRoleOptions
Was interface ByRoleOptions extends MatcherOptions; now interface ByRoleOptions. npmjs.com
@testing-library/dom 9.0.0-alpha.2 breaking changes
- Signature changed
ByRole
The role argument of ByRole must now be a string. Other values no longer work. github.com
@testing-library/dom 9.0.0-alpha.1 breaking changes
- Removed
Node.js 12.x is no longer supported. Users on Node.js 12 must upgrade to Node.js 14 or later. github.com
@testing-library/dom 8.0.0 breaking changes
- Removed
Node 10 is no longer supported. Upgrade to a newer Node.js version before using this release. github.com - Removed
wait
Use waitFor instead. npmjs.com - Removed
waitForDomChange
Use waitFor instead. npmjs.com - Removed
waitForElement
The deprecated waitForElement was removed in v8. Code that calls it must be updated before upgrading. npmjs.com - Removed
waitFormDOMChange
The deprecated waitFormDOMChange was removed in v8. Code that calls it must be updated before upgrading. github.com - Behavior changed
waitFor
The timeout option of waitFor now uses the same clock as interval, so mocked timers can affect it. To keep the old behavior, pass timeout: Number.POSITIVE_INFINITY and rely on the test runner timeout. github.com - Default changed
prettyDOM
By default prettyDOM skips script, style and comment nodes. To get the old output, pass a custom filterNode function that returns true. github.com - Signature changed
logDOM
Was function logDOM(dom?: Element | HTMLDocument, maxLength?: number, options?: prettyFormat.OptionsReceived): void; now function logDOM(dom?: Element | HTMLDocument, maxLength?: number, options?: PrettyDOMOptions): void. npmjs.com - Signature changed
prettyDOM
Was function prettyDOM(dom?: Element | HTMLDocument, maxLength?: number, options?: prettyFormat.OptionsReceived): string | false; now function prettyDOM(dom?: Element | HTMLDocument, maxLength?: number, options?: PrettyDOMOptions): string... npmjs.com
Related packages
- @testing-library/jest-dom
- @testing-library/preact
- @testing-library/react
- @testing-library/react-native
- @testing-library/user-event
Check your code
These are the changes. To see which of them reach your code, scan a public repository, or have your coding agent call check_code with your manifest or lockfile over MCP. The API reads every change in every version. A fix pull request opens for the changes that reach a connected repository. Nothing merges or deploys.

Put your code on continuous maintenance.
Scan a public repository now, or give your agent one line.
See how out of date your code is.
Tell your agent what changed since it was trained.
claude mcp add --transport http since https://api.since.dev/mcpCodex, Cursor and any MCP client use https://api.since.dev/mcp.