canon 0.4.0
canon: ^0.4.0 copied to clipboard
Compile-safe Flutter navigation from a single grammar.
0.4.0 #
- Self-pop:
popToXxnow reaches the previous occurrence of the screen you're on (resolvePopskips the current top) instead of no-opping, and it's chainable through a cycle —popToProfile().popToProfile()steps back two. Cycle-member pops are now on union navs too so chains keep a handle that still exposes them. (Relative/absolute "by n / at depth n" are just chaining + thedepthgetter — no extra verbs.) Generator no longer emits an unused_endsWithhelper for trees that don't use.under.
0.3.0 #
- Cycle navigation:
NavGraph.countOf(screen, [id])for cycle depth, adepthgetter on cyclic nav handles (Screen.at case XNav(:depth) when depth > 1), the one-shotScreen.on(.x([id]).depth(n))exact-match gate (compile-gated to cyclic screens), and throwing cycle-memberpopToXverbs guarded by those depth checks.
0.2.1 #
- Handle verbs (
goX/go(Hop)) are edge-required: a target unreachable from the live top throws instead of silently teleporting via the canonical fallback, and guaranteedpop/popTothrow when impossible — both release-active (replacing debug-only asserts). Stale-but-still-legal navigations still resolve; the globalScreen.goXteleport is unchanged.
0.2.0 #
- Stale-codegen guard:
Screen.isCodegenFresh+ a boot-time assert flag a tree that was re-parented without regenerating. - Replace the
againback-edge withcycled(folds a completed duplicate cycle) andstacked(stacks a fresh instance, preserving history).
0.1.0 #
- Initial release.