调整播放列表接口

This commit is contained in:
zhw2590582 committed 2019-05-01 10:57:49 +08:00
1 parent 941ab07c66
commit 6056e7a0c6
9 files changed
+223 -235

No files matched your search

+12 -13
View File
@@ -40,21 +40,20 @@ Will expose the global variable to `window.artplayerPluginPlaylist`.
var art = new Artplayer({
container: '.artplayer-app',
url: 'path/to/video.mp4',
plugins: [artplayerPluginPlaylist],
plugins: [
artplayerPluginPlaylist([
{
title: 'video01',
url: 'path/to/video01.mp4',
},
{
title: 'video02',
url: 'path/to/video02.mp4',
},
]),
],
});
// Load Playlist
art.plugins.artplayerPluginPlaylist.load([
{
title: 'video01',
url: 'path/to/video01.mp4',
},
{
title: 'video02',
url: 'path/to/video02.mp4',
},
]);
// Show Playlist
art.plugins.artplayerPluginPlaylist.show();