I’m trying to use WebView. I followed this article: https://developer.amazon.com/docs/vega/0.21/set-up-webview.html
Here’s a snapshot of the code:
App.tsx:
import { WebView } from ‘@amazon-devices/webview’;
import React, { useState, useEffect } from ‘react’;
import { View, StyleSheet } from ‘react-native’;
export const App = () => {
const [ready, setReady] = useState(false);
useEffect(() => {
const timer = setTimeout(() => setReady(true), 100);
return () => clearTimeout(timer);
},
);
return (
{ready && (
<WebView
hasTVPreferredFocus={true}
source={{ uri: ‘file:///pkg/assets/stack_game_enhanced.html’ }}
onError={(e) => console.warn(‘WebView error:’, e.nativeEvent)}
onHttpError={(e) => console.warn(‘HTTP error:’, e.nativeEvent.statusCode)}
onLoadStart={() => console.log(‘Load started’)}
onLoad={() => console.log(‘Loaded’)}
/>
)}
);
};
const styles = StyleSheet.create({
container: { flex: 1 },
});
**Manifest.toml:
**
schema-version = 1
[package]
title = “StuckGame”
version = “0.1.0”
id = “x.x.stuckgame”
[components]
[[components.interactive]]
id = “x.x.stuckgame.main”
runtime-module = “/com.amazon.kepler.keplerscript.runtime.loader_2@IKeplerScript_2_0”
launch-type = “singleton”
categories = [“com.amazon.category.main”]
[wants]
Web renderer - required for WebView
[[wants.service]]
id = “com.amazon.webview.renderer_service”
Keyboard support
[[wants.service]]
id = “com.amazon.inputmethod.service”
Accessibility
[[wants.service]]
id = “com.amazon.kepler.ucc.publisher”
Audio playback
[[wants.service]]
id = “com.amazon.audio.stream”
Audio management (focus, volume control)
[[wants.service]]
id = “com.amazon.audio.control”
Group-IPC for media services
[[wants.service]]
id = “com.amazon.gipc.uuid.*”
[offers]
[[offers.service]]
id = “com.amazon.gipc.uuid.*”
When I test on the virtual device provided by Vega Studio, I get this error:
2026-05-02 11:37:47.794 [info] vega device install-app --device “Simulator” --directory “/home/mouad/vegaprojects/StuckGame” --buildType “Debug” --packagePath “/home/mouad/vegaprojects/StuckGame/build/private/kepler/@amazon-devices/stuckgame/undefined/vega/x86_64/Debug/@amazon-devices/stuckgame_x86_64.vpkg”
2026-05-02 11:37:49.260 [warning] Vega operation FAILED due to an irrecoverable error: Failed: Installing/Updating ‘/tmp/stuckgame_x86_64.vpkg’ …error (Module dependency not found)
: error: Unable to install ‘/tmp/stuckgame_x86_64.vpkg’ as the required dependencies are not found on the device.
The Kepler Virtual Device is missing modules that are available on a physical device. Test your app using a Fire TV Stick instead.
The following module dependencies declared in the application manifest are not found:
/com.amazon.kepler.webview_3@IWebview_3
Could you please confirm whether WebView works only on real devices or not?
Thank you.