A locked version means exactly one tarball: the first install records its integrity (the registry's sha512), and an install that got different bytes for the same version is refused.
Install what `exts` import: each package at its locked version (picking one for ranges not locked yet), under its range's alias, with DefinitelyTyped types (`@types/react`) beside packages that ship none.
Point each installed package's peers at the locked range its peer range accepts. Package managers resolve a peer by name across the whole install, so with two ranges of React in the cache, React DOM 18 could get React 19 (pnpm), or a second copy at the same version (npm). Two copies of one React break it, and the wrong one breaks it worse. A link inside the package wins: Node resolution looks there first.
One copy of each package version in the cache. npm installs a package a peer asks for (React, for React Aria's own packages) at its name, beside the alias tcm installed it under: two copies of one version, which React can't be (two Reacts break hooks). A package at its name that's a locked version becomes a link to that version's alias. Run after each install (npm puts its copy back).
Pick versions for packages the lock doesn't have yet: the newest in each range whose peers accept what's locked. Peers among the packages being picked are picked first, so React comes before React DOM.
`<package manager> view <args>`, asked again (twice, a moment apart, then longer) when it fails other than by the package or version not being there: a registry that didn't answer once (a timeout, a dropped connection) isn't a package that doesn't exist. `view` and `pause` are for tests.
A package tcm ships, installed with it: its directory and version. Undefined for others, and where tcm has none beside it. The directory is the package's own, links followed. Run from its codebase, tcm ships what the codebase installed for it (its package's `with`), in the cache it runs from: at its name (Vitest, through the cache's link to it), or else under its alias, as its browser test runner is (all of it, so they're one install: a codebase given Vitest linked and its browser side installed gets two that don't fit).
The packages tcm ships (dependencies of the tcm-ts package, at the versions its tests ran): the tools it runs (oxlint, oxfmt, the React Compiler) and its test runner (Vitest, which tests import, and its browser side).
Raise the lock for `name` within `range` to at least `version`: code was checked against it, and within a compatible range a newer version only adds (semver). Returns the version before, if it changed.