Multi Format Playlist Selection

Vimeo Playlist With Mp4 videos

    <div class="flex w-full h-auto my-auto">
      <video class="video-js vjs-default-skin vjs-fluid " crossorigin="anonymous" controls="" id="multi-playlist"></video>
  </div>
  <script type="text/javascript">
  	var player = videojs("multi-playlist", {
    "controlBar": {
        "pictureInPictureToggle": false
    },
    "playbackRates": [
        0.5,
        1,
        1.5,
        2
    ],
    "plugins": {
        "qualitymenu": {},
        "vimeo": {
            "pro": true
        }
    }
});

  
          const playlistPlugin = player.playlistPlugin(player, {});
          const PlaylistPluginClass = videojs.getPlugin('playlistPlugin');

        
          const videoList = [
    {
        "name": "Big Buck Bunny",
        "sources": [
            {
                "src": "https://vimeo.com/1084537",
                "type": "video/vimeo"
            }
        ]
    },
    {
        "name": "Elephants Dream",
        "sources": [
            {
                "src": "https://vimeo.com/1132937",
                "type": "video/vimeo"
            }
        ]
    }
];
          const playlist = PlaylistPluginClass.createPlaylistFrom(videoList);

          // Plugin methods
          playlistPlugin.loadPlaylist(playlist);
          player.playlistUi({playOnSelect: true});

          playlistPlugin.loadFirstItem();
          playlistPlugin.setAutoadvanceDelay(0);
  </script>