# What changed in d3-selection

> 15 changes in d3-selection 2 to 3 from its official release notes, upgrade guides and advisories: 12 breaking, 1 new APIs and options. Each one cited. Sources checked 2026-11-05. HTML: https://unstale.sh/npm/d3-selection/

To see which of these apply to a repository, run `npx @unstale/cli init` in it.

## d3-selection 3

### Breaking changes

- The package now publishes an ES module bundle instead of separate source files, changing the published package contents. (3.0.1) — [release notes](https://github.com/d3/d3-selection/releases/tag/v3.0.1)
- The package now requires Node.js 12 or higher. (3.0.0) — [release notes](https://github.com/d3/d3-selection/releases/tag/v3.0.0)
- Adopts type: module, affecting how the package is interpreted by Node.js. (3.0.0) — [release notes](https://github.com/d3/d3-selection/releases/tag/v3.0.0)

### Behavior and default changes

- Converts array-like inputs, such as live NodeLists, to arrays. (3.0.0) — [release notes](https://github.com/d3/d3-selection/releases/tag/v3.0.0)
- Converts array-like inputs, such as live NodeLists, to arrays. (3.0.0) — [release notes](https://github.com/d3/d3-selection/releases/tag/v3.0.0)

## d3-selection 2

### Breaking changes

- Removes d3.clientPoint. (2.0.0) — [release notes](https://github.com/d3/d3-selection/releases/tag/v2.0.0)
- Removes d3.customEvent. (2.0.0) — [release notes](https://github.com/d3/d3-selection/releases/tag/v2.0.0)
- Removes d3.event. (2.0.0) — [release notes](https://github.com/d3/d3-selection/releases/tag/v2.0.0)
- Removes d3.mouse. (2.0.0) — [release notes](https://github.com/d3/d3-selection/releases/tag/v2.0.0)
- Removes d3.sourceEvent. (2.0.0) — [release notes](https://github.com/d3/d3-selection/releases/tag/v2.0.0)
- Removes d3.touch. (2.0.0) — [release notes](https://github.com/d3/d3-selection/releases/tag/v2.0.0)
- Removes d3.touches. (2.0.0) — [release notes](https://github.com/d3/d3-selection/releases/tag/v2.0.0)
- Fixes selection.merge to error when passed a transition. (2.0.0) — [release notes](https://github.com/d3/d3-selection/releases/tag/v2.0.0)
- Listeners no longer receive index and group. (2.0.0) — [release notes](https://github.com/d3/d3-selection/releases/tag/v2.0.0)

### New APIs and options

- Selections become iterable. (2.0.0) — [release notes](https://github.com/d3/d3-selection/releases/tag/v2.0.0)
