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

fix(router-utils): accept #__NO_SIDE_EFFECTS__ before a const declaration

Rollup and esbuild read the annotation before a `const` statement (or
around its `export`) as its first declarator's when that declarator is a
function; the compiler read it only before the initialiser, so a route
annotated as the Rollup docs show kept its declaration eager and warned.
Same-file callees only, as before. Docs list the accepted placements.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
Sheraff 2026-11-09 16:22:05 +01:00
commit 3aecde8cde
No known key found for this signature in database
2 changed files with 14 additions and 4 deletions