Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix ReactPlayer refs not being set #866

Closed

Conversation

alexivanov
Copy link

This fixes an issue and where player and wrapper refs are not set correctly in ReactPlayer, causing instance methods to stop working. Tested with v2.0.0 and I think this version is the only one affected.

Introduced in 9c9a4d4.

@@ -42,7 +42,7 @@ export default class ReactPlayer extends Component {
showPreview: !!this.props.light
}

refs = {
elementRefs = {
Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

refs overshadows legacy React.Component prop and is overwritten.

@cookpete cookpete closed this in 3c6ff8d Apr 28, 2020
@cookpete
Copy link
Owner

Fixed separately in v2.0.1. Cheers for the PR!

albanqoku added a commit to albanqoku/react-player that referenced this pull request Feb 24, 2021
Webmaster1116 added a commit to Webmaster1116/video-player that referenced this pull request May 20, 2021
webmiraclepro added a commit to webmiraclepro/video-player that referenced this pull request Sep 9, 2022
philip-luther added a commit to philip-luther/react-player that referenced this pull request Nov 22, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants