youtube-apiyoutube-javascript-api

YouTube JavaScript API: use of "unstarted" state


From the player documentation: "When the player first loads a video, it will broadcast an unstarted (-1) event."

What's the intended use of this event? That is, what would my host code do differently, as a consequence of seeing it, than it would if the state didn't exist? The example code I've seen does nothing but log it.


Solution

  • I don't imagine that it's very useful. I don't think there's some deeper truth that you're missing out on. I assume it reflects a state that's mainly used internally by the player itself and it was exposed in the API for the sake of completeness.