Creating a simple video playlist

Example

See the Pen Videogular – Create a Simple Playlist by Two Fucking Developers (@2fdevs) on CodePen.

Description

Playlists are fun!

This is the most basic playlist that you can made with Videogular. Everything works with bindings where controller.config.sources is your media file to play and controller.videos your playlist.

Since everything is bindable you can call to setVideo(index) from your HTML and Videogular will react to those changes setting the new video source and calling again onPlayerReady to start again.

In this example we also added a callback to onComplete to have a continuous playing through the entire list. If you combine this with MP3 files you can build in a few lines a complete music player!