Fires when one of the signed-in listener's playlists is made, changed or deleted.
Also dispatched as the riff:playlist event on #riff, with the same detail. The event bubbles.
Parameters
detailObject- What changed.
changestringcreate,add,rename,reorder,removeordelete.playlistObjectThe playlist,{ id, title, count }.playlistsObject[]Every playlist, the most recently changed first.
apiObjectwindow.riff.
More Information
Usage
wp.hooks.addAction( 'riff.playlist', 'my-plugin', ( detail, api ) => {
} );
// Or, without wp-hooks:
window.riff.on( 'playlist', ( detail ) => {} );Source
emit( 'playlist', {
change,
playlist: brief,
playlists: api.playlists(),
} );plugins/riff/assets/riff.jsView on GitHub
Changelog
| Version | Description |
|---|---|
| 4.20.0 | Introduced. |