Reflex wrapped players are not destroyed correctly
Closed this issue · 0 comments
SeqCrafter commented
I've wrapped Artplayer with Reflex and added two pages. When I first click a link from the homepage to the playback page, everything works fine. However, when I return to the homepage, the player continues playing the video in the background. When I click the homepage link again to return to the playback page, the previous player and the new player use the old play link, and the new player uses the new play link, for a total of three players playing the video. This is very strange. I've correctly set the player destruction code in useEffect, but I don't know why this strange behavior occurs.
I wrote a simple demo to demonstrate this problem, please check the code repository: