1 unstable release
Uses new Rust 2024
| 0.1.0 | Apr 8, 2026 |
|---|
#5 in #expensive
Used in 3 crates
1.5MB
37K
SLoC
Selector-style derived state helpers (ecosystem-level).
This crate provides a small, explicit "derived state" primitive:
- memoize an expensive computation behind a dependency signature (
Deps: PartialEq) - keep the kernel (
fret-ui) mechanism-only (ADR 0066)
A selector is intentionally not a global reactive graph. It is a local cache that can live in:
- element state (
ElementContext::with_state_*) via the optionaluifeature, or - app/window state (e.g. inside a
Model<T>payload)
Design constraints:
- no hidden
ModelStoreborrows across user code (user code runs outside of any store guard) - dependency tracking is explicit: callers must provide a dependency signature
fret-selector
Derived state selector utilities for Fret apps and components.
A selector is a small, explicit derived-state primitive:
- memoize an expensive computation behind a dependency signature (
Deps: PartialEq) - keep dependency tracking explicit (no hidden global reactive graph)
Status
Experimental learning project (not production-ready).
Features
ui: element-context helpers for collecting dependency tokens while registering observations
Dependencies
~4.5–9.5MB
~94K SLoC