Developer Docs - Apple TV Docs - RockTvApp

Application Images

Methods

The RockTvApp supports the following methods.

AppState

The RockTvApp has an AppState property that provides state information about the application. These values come from the shell logic. This is a bridge between the shell and the application. These are intentionally named the same as Rock Mobile when possible.

Helper Functions

Below are a set of the helper functions available to you.

createAlertDocument(title, description)

The function will return a TVML document with the title and description inserted. The alert is rather plain, but you can override it in your application. The primary reason it's defined in the Shell is to allow for handling errors when things don't go well loading the application's JavaScript.

var alert = RockTvApp.createAlertDocument("Made It", "Looks like we made it.");