v0.6.0 — the event-source seam
v0.6.0 — the event-source seam
Sub had one kind, :interval, and it is a timer — the runtime wakes itself.
Everything else worth subscribing to is the opposite shape: an external source
pushes, and the runtime receives without that source knowing anything about
rendering. This release is that seam, the two consumers that prove it, and the
widget that makes them worth looking at.
Added:
Sub.telemetry/2— subscribe to:telemetryevents. Phoenix, Ecto, Oban,
Broadway, Finch and Bandit all already emit telemetry, so integrating with
that one thing covers the ecosystem rather than one library.Sub.logger/1— a:loggerhandler, withHarlock.Sub.Logger.text/1for
rendering entries. Built second, and deliberately different, to test whether
the seam generalises before four more kinds depend on it. It did: neither
needed a change toSub.start/2or to the runtime's subscription diffing.sparkline/1— a one-line trend.progress/1shows a fraction; this shows a
history, right-aligned so the newest sample stays at the right edge.box(focus_proxy: :child_id)— a container mirrors a child's focus for
styling without joining focus traversal, which:focusableon the
interactive widget otherwise makes impossible.examples/dashboard.exs— all of the above in one screen.
Fixed:
- A terminal reporting 0x0 no longer produces a 0x0 frame.
TIOCGWINSZ
succeeds while reporting zero on a tty that was never told its geometry (a
serial console), and0 || 24is0in Elixir, so the fallback never fired
and the app drew nothing — presenting as a hang.
pubsub, file, signal and port moved to v0.7. The seam they need exists,
so they are additions rather than design work, and holding a finished release
for them would have been holding it for nothing.
Full notes in CHANGELOG.md.