Closed jorjordandan closed 2 months ago
The latest updates on your projects. Learn more about Vercel for Git ↗︎
Name | Status | Preview | Comments | Updated (UTC) |
---|---|---|---|---|
drei | ✅ Ready (Inspect) | Visit Preview | 💬 Add feedback | Apr 12, 2024 9:21pm |
This pull request is automatically built and testable in CodeSandbox.
To see build info of the built libraries, click here or the icon next to each commit SHA.
Continued in #1919. Thanks for the help!
@CodyJasonBennett Thanks for this, I tried something similar but keep in mind that the hlsRef
on the useEffect is null so I think this cleanup:
return () => {
if (hlsRef.current) {
hlsRef.current.destroy()
hlsRef.current = null
}
}
will never run.
If hlsRef
is ever non-null before unmount, that will run. #1919 doesn't alter cleanup behavior.
fixes #1917. Moves useVideoTexture to /web. Also fix reference from faceControls.
Why
Currently, useVideo texture imports hls.js. This import triggers a check to navigator, which causes an error because navigator doesn't exist on react native. It's not possible to dynamically import it without making it into an async function which would cause other issues.
What
I've moved useVideoTexture from core to web, since it does not work on native anyways.
Checklist
Also fixed one reference to useVideoTexture from faceControls.