Expo Web (iframe embed)
When you target Expo Web, Moviie playback uses the same watch iframe and Player JS API as a browser integration; not expo-video inside RN Web.
Expo Web (iframe embed)
When you run your Expo app on web (expo start --web), @moviie/player-expo resolves platform-specific modules:
useMoviiePlayerreturnsplayer: null. Playback metadata still comes fromgetPlaybackviauseMoviiePlayback/ the SDK.MoviieVideorenders aniframewhosesrcis the public embed URL:{watchOrigin}/embed/{embedId}(same route as Iframe code).
Treat web like an embed integration: load embed.js from the watch origin (the package injects it once by default) and use the Player API (window.Moviie, postMessage, Moviie.getPlayer(iframe)) as documented for websites; see Quick start (web) and Player API overview.
Publishable key is optional on web
The iframe mounts immediately from the embedId you passed to useMoviiePlayer — it does not wait for (or require) the playback fetch, because the public embed authorizes itself. Configuring the publishable key on web is still useful: it lets the hook populate playback (title, poster, controls metadata) for your own UI. Without it, playback stays null and error reports the missing key, while the player keeps working.
Configuration
EXPO_PUBLIC_MOVIIE_WATCH_ORIGIN: Optional override for the watch/embed origin (no trailing slash). Defaults to productionhttps://watch.moviie.ai.- The embed script URL is
{watchOrigin}/embed.js(seeMOVIIE_WATCH_EMBED_JS_PATHin the package).
Optional MoviieVideo props on web:
onEmbedIframeRef: Callback with a minimal handle (contentWindow.postMessage) after the iframe mounts; align withMoviie.getPlayerwhen usingembed.js.loadEmbedScript: Defaulttrue. Setfalseif your host page already loadsembed.jsglobally.
What is not supported on Expo Web (vs iOS / Android)
These rely on expo-video, native modules, or the React Native Moviie chrome; they do not apply inside the iframe layer:
| Capability | On native | On Expo Web |
|---|---|---|
VideoPlayer instance from useMoviiePlayer | Yes | null: control playback via Player API / iframe |
| Custom Moviie skin (timeline, HUD, RN fullscreen modal, etc.) | Yes | No: UI is the web embed inside the iframe |
Telemetry wired to expo-video in your app | Yes | Not applicable: embed handles player telemetry internally |
rememberPosition persistence via SecureStore / native resume hook path | Yes | Not implemented in the package on web; embed may apply its own rules |
backgroundPlayback, lockScreenNowPlaying | Native useMoviiePlayer options | Ignored on web |
videoPresentation / VideoView PiP props | Passed to VideoView | Not applied to the iframe element; PiP/fullscreen follow browser + embed |
The forwarded ref type MoviieVideoSurfaceRef on web is a stub (no-op methods); use the Player API for real controls.