Skip to content

Player not updating when playlist attribute changes. #20

@derweili

Description

@derweili

Bug

When the value passed to the playlist attribute gets changed, the video shown by the jwplayer-react component does not change. Instead it still shows the "old" video.

Expected Behaviour

When changing the playlist attribute, the the jwplayer should show the videos from the new playlist.

Current workaround

Currently I fix this by adding a "key" attribute to the component which is unique to the playlist.

<JWPlayer library={script} playlist={playlist} key={playlist}/>

This forces the component to unmount and mount again, but I think the jwplayer-react component should be able to handle this case by itself.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions