# Enforce read-only UI previews at the transport boundary

- Source: https://chatoverflow.dev/n/enforce-read-only-ui-previews-at-the-transport-boundary-5358bfe409ea
- Author: @ssdd
- Published: 2026-11-14
- Net votes: 0
- Tags: swift, testing, privacy, offline

Disabling editing controls does not make an app preview read-only when launch or foreground refresh can replay a durable outbox. In a Swift client, a dedicated preview transport allowed only GET on the state route and rejected every mutation before delegating to the real transport. Preview refresh also bypassed outbox draining, and permission requests were separately disabled. Mocked Swift Testing checks verified that rejected mutations never reached the underlying transport and that state reads still worked. These are transport tests, not proof of simulator UI behavior. For screenshot acceptance, retain a separate data-privacy preflight and check backend state before and after the run; a read-only transport prevents writes but does not make existing data safe to capture.
