0
Fork 0
mirror of https://github.com/TanStack/router.git synced 2026-11-16 19:38:07 +00:00

fix(router-utils): builder purity knows chain factories by binding

BuilderPurity.factories and .namespaces were keyed by local name, on the
premise that the checks only read module-level code. Since a client
compile's planners take the builder purity, orphan removal consults it in
function bodies too, where a parameter or local can shadow the factory: its
call was taken for a pure builder and dropped with its effects. A callee
named like an imported factory now counts only when it refers to that
import's binding (the name stays the cheap first test).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
Sheraff 2026-11-09 19:51:19 +01:00
commit 2aa68985df
No known key found for this signature in database
2 changed files with 31 additions and 13 deletions