Skip to content

docs: 1358 — lay the route-atom docblocks out as caller documentation - #126

Merged
randomdevpete merged 3 commits into
masterfrom
task-1358-route-atom-docblocks
Sep 7, 2026
Merged

randomdevpete merged 3 commits into
masterfrom
task-1358-route-atom-docblocks

Conversation

@randomdevpete

Copy link
Copy Markdown
Owner

validateRouteAtom, numericRouteAtom, transformRouteAtom and queryParamRouteAtom each carried a single run-on paragraph that spliced an example mid-sentence and closed with a justification for the design; useRoute and Link closed with the same. They now use the form asyncRouteAtom, navigationGuardAtom, locationAtom and enumRouteAtom already use: a one-line summary, a fenced example where one earns its place, then a short line per caller-facing constraint.

Every genuine gotcha is kept — the inclusive min/max range, the non-matching fall-through, the predicate's Getter, setter having to produce values the parent accepts, and query params consuming no path segments. Cut is the internals and design narration; the "a paramRouteAtom with a transformRouteAtom on top" explanation already lives where it belongs, in the custom-route-atoms guide.

No behaviour change. Build, typecheck, lint and both packages' unit suites pass, and the generated API reference pages render the new examples as code blocks.

🤖 Generated with Claude Code

https://claude.ai/code/session_01TYNkcK3xGhfZRqkjXqjBu5

randomdevpete and others added 3 commits September 7, 2026 03:04
… out as caller documentation

One-line summary, a fenced example where one earns its place, then a short line per caller
contract. The range behaviour, the non-matching fall-through and the predicate's `Getter` stay;
the composition-from-primitives narration goes, and the guide on custom route atoms already
carries it.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01TYNkcK3xGhfZRqkjXqjBu5
…r documentation

The last route atom in the same run-on shape. Composition, the reverse/write round-trip and the
"consumes no path segments" contract each get their own line.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01TYNkcK3xGhfZRqkjXqjBu5
…te docblocks

`useRoute` argued for its own name; `Link` described itself as a thin wrapper over `useLink`.
Both keep the fact a caller needs — that `useRoute` is `useAtomValue`, and that `useLink` is
there for markup that isn't anchor-shaped.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01TYNkcK3xGhfZRqkjXqjBu5
@randomdevpete
randomdevpete merged commit 1fa29cf into master Sep 7, 2026
6 checks passed
@randomdevpete
randomdevpete deleted the task-1358-route-atom-docblocks branch September 7, 2026 21:25
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant