Basics
Debugging in Hosanna UI
For the fastest and most productive debugging experience, it is recommended to debug your Hosanna app in the web environment first.
Web Debugging Advantages
- JavaScript Debugger: Use the browser's built-in JavaScript debugger to set breakpoints, step through code, and inspect variables.
- Console Output: View, filter, and clear logs in the browser console. Click on log lines to jump to the relevant source code.
- Network Monitor: Inspect network requests and responses in real time.
- Disable Cache: You can disable the browser cache in dev tools for more predictable reloads.
- VSCode Debugger: You can also debug directly in VSCode, set breakpoints, step through the stack, and view console output.
Device Debugging
While debugging on device is supported (see the Native Development Roku guide), web debugging is generally faster and more flexible. Use device debugging for final integration and platform-specific issues.
Special Launch Query Strings
You can launch the app with special query strings for advanced scenarios:
-
Deeplinking: Use query parameters like
mediaType
andcontentId
(as per Roku's deeplinking spec) to launch the app into specific content or states.?mediaType=movie&contentId=12345
-
Text-to-Speech: Enable text-to-speech features by adding:
?textToSpeech=true
-
Clear Registry Command: You can clear the app's registry by launching with:
?mediaType=hosannaCommand&contentId=clearRegistry
(Hosanna uses the
mediaType=hosannaCommand
hack to support special commands via deeplinking arguments.)
Refer to your browser and VSCode documentation for more details on debugging features and workflows.