Skip to main content
RequestDisplayMode asks the host to change how the app is displayed — switching between inline, fullscreen, or picture-in-picture. The host decides whether to honor the request, so the actual mode may differ from what you asked for.

Display Mode Toggle

Use the HOST reactive variable to show the right button based on the current display mode. The host context is automatically available as $host in the renderer’s state:

API Reference

RequestDisplayMode Parameters

mode
"inline" | "fullscreen" | "pip"
required
The display mode to request. Can be passed as a positional argument. The host may not support all modes — use onError to handle rejection.

Protocol Reference

RequestDisplayMode
{
  "action": "requestDisplayMode",
  "mode": "\"inline\" | \"fullscreen\" | \"pip\" (required)"
}
For the complete protocol schema, see RequestDisplayMode.