Update shaka when nativeRef changes

This commit is contained in:
Ivan Malison 2024-10-13 19:17:01 -06:00
parent 0e9ac4d125
commit 81e864c0e1

View File

@ -254,8 +254,8 @@ const Video = forwardRef<VideoRef, ReactVideoProps>(
shakaPlayerRef.current.load(source?.uri).then( shakaPlayerRef.current.load(source?.uri).then(
() => console.log(`${source?.uri} finished loading`) () => console.log(`${source?.uri} finished loading`)
); );
console.log("STarted shaka loading"); console.log("Started shaka loading");
}, [source]) }, [source, nativeRef.current])
useMediaSession(source?.metadata, nativeRef, showNotificationControls); useMediaSession(source?.metadata, nativeRef, showNotificationControls);