Skip to main content

Crate gpui_tea

Crate gpui_tea 

Source
Expand description

Build Elm-style GPUI programs with composable models, commands, and subscriptions.

gpui_tea packages the runtime primitives needed to drive a The Elm Architecture style application on top of gpui. The crate exposes:

Most applications implement Model and mount it with Program::mount() or ModelExt::into_program().

Structs§

ChildPath
Identify a model’s position inside a nested program tree.
ChildScope
Bridge a child Model into a parent model’s message space.
Command
Describe work the runtime should perform after a model transition.
Dispatcher
Send messages back into a mounted crate::Program.
Key
Identify a keyed effect or subscription across reconciliations.
ModelContext
Carry structural context for a Model invocation.
Program
Host a mounted Model inside the GPUI runtime.
ProgramConfig
Configure runtime observability hooks and queue behavior.
ProgramId
Identify a mounted program instance in observability output.
RuntimeSnapshot
Snapshot runtime bookkeeping for a mounted Program.
Subscription
Declare a long-lived external event source for a program.
SubscriptionContext
Expose runtime services while constructing a Subscription.
Subscriptions
Collect a set of unique Subscription values.
TelemetryEnvelope
Wrap a telemetry event together with its metadata.
TelemetryMetadata
Carry metadata emitted with each TelemetryEvent.
View
Wrap a GPUI element returned from crate::Model::view().

Enums§

CommandKind
Classify how a Command interacts with the runtime.
Error
Report runtime and subscription construction failures.
QueueOverflowAction
Describe the action taken when a queue reaches capacity.
QueuePolicy
Define how the runtime handles queue backpressure.
RuntimeEvent
Describe high-level runtime events intended for application observers.
SubHandle
Hold the runtime resource that keeps a subscription alive.
TelemetryEvent
Describe detailed runtime telemetry intended for machine consumption.

Traits§

IntoView
Convert a GPUI element into a View.
Model
Define state, message handling, and rendering for a TEA program.
ModelExt
Mount a Model as a fully initialized Program.

Functions§

observe_metrics_telemetry
Record a TelemetryEnvelope as metrics counters and gauges.
observe_tracing_telemetry
Record a TelemetryEnvelope as tracing events.

Type Aliases§

Result
Alias the crate-wide result type.

Derive Macros§

Composite
Derive child-model forwarding helpers for a composite model struct.