A dev/test-only in-memory Flicker.RecentValues store
(Spec 022).
Not durable, not shared across nodes, and gone on restart. It exists so the
playground can demonstrate the Recent group and so tests have a real store
to drive, not as something to point a production app at — see
Flicker.RecentValues for why Flicker deliberately owns no persistence.
Usage
Flicker.RecentValues.Ets.start()
<Flicker.search
recent_values={Flicker.RecentValues.Ets.config()}
...
/>Entries are keyed by {scope, facet_key, value}, where scope is derived
from the :actor in opts — so two actors in the same dev session don't see
each other's history, mirroring what a real host's per-user storage would do.
Summary
Functions
Clears everything. Test support.
The recent_values config map to hand to a component.
Every recorded usage for facet_key in the caller's scope, as
{value, used_at, count} triples.
Records one use of value, bumping its count and its timestamp.
Creates the backing table if it doesn't exist. Idempotent.
Functions
@spec clear() :: :ok
Clears everything. Test support.
The recent_values config map to hand to a component.
@spec load(atom(), keyword()) :: [Flicker.RecentValues.usage()]
Every recorded usage for facet_key in the caller's scope, as
{value, used_at, count} triples.
Returns facts, not an opinion — Flicker.RecentValues.rank/2 does the
ordering, so ranking stays one testable function rather than something each
store reimplements.
Records one use of value, bumping its count and its timestamp.
@spec start() :: :ok
Creates the backing table if it doesn't exist. Idempotent.