chore(deps): drop unused transitive @tanstack/react-table from the install graph - #1917
chore(deps): drop unused transitive @tanstack/react-table from the install graph#1917stipsan wants to merge 1 commit into
Conversation
…stall graph The pinned sanity@next prerelease still declares @tanstack/react-table (v8) as a dependency, but nothing imports it: its only consumer (the sheet list) was removed in sanity-io/sanity#12477 and the dependency itself in sanity-io/sanity#14121. A scoped pnpm removal override ('sanity>@tanstack/react-table': '-') drops the unused, React Compiler-incompatible v8 package from this workspace until a next prerelease ships without it.
|
|
The latest updates on your projects. Learn more about Vercel for GitHub.
1 Skipped Deployment
|
❌ E2E Tests🟢 22 passed • 🔴 4 failed • view full report • view run 🤖 Share with an AI agent:
Studio: https://plugins-e2e-test-studio-8otf1rasl.sanity.dev Datasets: Debug failing tests locallySANITY_E2E_PROJECT_ID=a1psl692 \
SANITY_E2E_BASE_URL=https://plugins-e2e-test-studio-8otf1rasl.sanity.dev \
SANITY_E2E_DATASET_CHROMIUM=pr-1917-chromium-32151194439 \
SANITY_E2E_DATASET_FIREFOX=pr-1917-firefox-32151194439 \
pnpm test:e2e --headed \
tests/document-internationalization/document-internationalization.spec.ts |
Coverage Report
File CoverageNo changed files found. |
Description
Started as the
@tanstack/react-tablev8 → v9 upgrade from sanity-io/sanity#14114, applied to this monorepo while following the React Compiler guide thoroughly. Working through the guide surfaced that there is nothing to upgrade or migrate here — but there is something to remove.Audit results (what the guide asks you to check):
@tanstack/react-table, and no source file references any of its APIs (useReactTable,useTable,flexRender,createColumnHelper,getCoreRowModel,TableMeta,Subscribe).@sanity/tableis a custom implementation,sanity-plugin-mediarenders its table view withreact-virtuoso.reactCompiler: truein eachtsdown.config.ts) and enforced via thereact/react-compileroxlint rule, so a v8useReactTableconsumer here would be a real hazard — v8 is the canonical interior-mutability example in React'sincompatible-librarylint docs. The repo's only'use no memo'directive (media plugin's asset details form) is a react-hook-formregister()issue, unrelated to tables.@tanstack/*dependencies in this repo (react-queryv5 in the Vercel widget,react-virtualv3 in workflow) are not covered by the Table v9 rework;react-virtualhas no store-based, compiler-ready major to move to yet (latest is 3.14.9).sanity(pinned to thenextdist-tag):pnpm whyshows no other path, and the installedsanity@6.10.0-next.53build has zeroreact-tablereferences outside itspackage.json— the sheet-list consumer was removed in sanity-io/sanity#12477 and the dependency itself in sanity-io/sanity#14121 (merged today).The change: a scoped pnpm removal override,
'sanity>@tanstack/react-table': '-', drops the unused package (and@tanstack/table-core) from the lockfile and install graph now. Scoping it to thesanity>edge means it self-neutralizes once the pinnednextprerelease ships without the dependency, and it cannot interfere if a plugin ever adopts table v9 directly — at which point the override should be deleted (noted in the comment).Why not wait for the upstream release?
Release @nextin sanity-io/sanity runs on a schedule (~07:17/14:13 UTC); today's second run started before #14121 merged (14:24 UTC), so the currentsanity@next(6.10.0-next.87) still declares^8.21.3. Also worth flagging: a plain lockfile re-resolution tonext.87is currently blocked anyway — it pulls@sanity/sdk@3.0.0-rc.1, which fails the workspacetrustPolicy: no-downgradecheck (no provenance on the RC while earlier versions had it). That is a pre-existing condition this PR does not touch; the lockfile was therefore edited surgically (verified:pnpm installreportsAlready up to date, and a clean reinstall produces a tree wheresanity's virtual-store dirs no longer linkreact-table).What to review
pnpm-workspace.yaml— the scoped override and its removal notepnpm-lock.yaml— removals only: the override mirror, the@tanstack/react-table@8.21.3+@tanstack/table-core@8.21.3package/snapshot entries, and the threesanitysnapshot edgesTesting
No changeset — no published package's
package.jsonor runtime code changes (workspace config + lockfile only, same as the dedupe PRs). Verified locally on the branch:pnpm install --frozen-lockfilefrom a cleannode_modules(tree confirmed free of react-table)pnpm format— no diffspnpm lint— passpnpm knip— passpnpm build— 52/52 taskspnpm test run— 211 files, 1283 tests, all pass