Skip to content

alertView

Wesley De Groot edited this page Nov 24, 2015 · 6 revisions

tvOS.alert(...)

Example (gif)

listView

Example code:

please note, the loading screen is removed in this example

evaluateScripts(['https://wesdegroot.github.io/tvOS.js/tvOS.js'], function (success) {
  if (success) {
    //
    // Display a cool alert :)
    tvOS.alert('Hi 😀', 'i\m a:', ['apple', 'tv', 'app', '😎'], function (event) {
      //
      // Display another 'weird' Alert
      tvOS.alert('Hi 😀', 'Event=' + event + '\ncan i reload?', ['Reload'], function () {
          tvOS.reload()
      })
    })
  } else {
    console.log('Missing it all!')
  }
})

Discussion

Go to: issues/2