Interface for managing a collection of timeline items.
A playlist allows switching between multiple timeline configurations (e.g., multiple videos, multiple animation sequences).
playlist.onItemChange((item) => { console.log(`Switched to: ${item.uri}`);});playlist.selectItem('chapter-2'); Copy
playlist.onItemChange((item) => { console.log(`Switched to: ${item.uri}`);});playlist.selectItem('chapter-2');
Type of playlist items (default: unknown)
Readonly
Currently active playlist item
All items in the playlist
Register a callback for item changes.
Called whenever the current item changes via selectItem().
selectItem()
Function receiving the new current item
Select a playlist item by identifier.
Unique identifier for the item (e.g., URI, ID)
If no item matches the identifier
Interface for managing a collection of timeline items.
A playlist allows switching between multiple timeline configurations (e.g., multiple videos, multiple animation sequences).
Example