Skip to content
New issue

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

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

Already on GitHub? # to your account

Event handlers not working at all #1059

Open
saidarshan27 opened this issue Apr 20, 2023 · 2 comments
Open

Event handlers not working at all #1059

saidarshan27 opened this issue Apr 20, 2023 · 2 comments

Comments

@saidarshan27
Copy link

saidarshan27 commented Apr 20, 2023

Event hadnlers like onPlay, onClick, onPause not working at all. I tried to reproduce it in a codesandbox.

import "./styles.css";
import Plyr from "plyr-react";
import "plyr-react/plyr.css";

export default function App() {
  return (
    <Plyr
      type="youtube"
      videoId="umldliRDefQ"
      onPlay={() => console.log("playing")}
      onClick={() => {
        console.log("clicking");
      }}
    />
  );
}

Steps to reproduce the behavior:

  1. Go to (https://codesandbox.io/s/recursing-morning-b1mk1t?file=/src/App.js

Expected behavior
I want a callback to be run onPlay, onPause, onSeek to attach custom handlers.

[https://stackoverflow.com/questions/76065265/plyr-react-event-callbacks-not-working-at-all](stackoverflow question)

@saidarshan27 saidarshan27 changed the title Event callbacks not working at all Event handlers not working at all Apr 20, 2023
@metacoding
Copy link

Yes I confirm this issue exists, a few handlers work others don't

@sloreti
Copy link

sloreti commented Jan 16, 2025

# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants