Stateless Editor Panel as Pure Projection
Stateless Editor Panel as Pure Projection
An editor panel (sidebar, inspector, properties pane) that holds no internal state of its own — it is fully re-rendered from the selected item's data model on every selection change. Changes in the panel write directly back to the model; the panel itself owns nothing.
The consequence is simplicity: there is no synchronization problem between "what the panel shows" and "what the model contains," because the panel is always derived from the model. Switching selection discards the old panel entirely and builds a fresh one from the new item's config. There is no stale UI state to manage.
The cost is that transient UI state (expanded sections, scroll position, focus) is lost on every re-render. This is acceptable when the panel is simple enough that users don't need persistent state within it. For more complex editors, the pattern still applies but requires explicitly lifting any persistent UI state into the model.
Source: data-app-factory — #014 Studio: Configuration sidebar See also: Declarative Data Apps, Config Schema and Runtime Unified in a Single Renderer