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

TypeError: Cannot read properties of undefined (reading 'stopProcessVideo') when running nextjs #13

Open
elblogbruno opened this issue Dec 19, 2023 · 2 comments

Comments

@elblogbruno
Copy link

I am trying to run mindar on nextjs 14, but I have not been succesful. Whetever I use AFrame or Three, I get this error:

image

What could it be?
Thanks

@amcc
Copy link

amcc commented Oct 15, 2024

i have exactly the same issue - i'll put something on the mind-ar repo and link to this too, but did you solve this

@amcc
Copy link

amcc commented Oct 15, 2024

fixed this here:
hiukim/mind-ar-js#549 (comment)

The issue is that strictMode mounts, unmounts then remounts the component. The stop function gets run in that process. I think this points to more checking needed within the stop function perhaps to account for the video not being started yet. I don't think react strict mode should really cause this error, but it is.

One solution would be to turn off strict mode, i wouldn't, the above link uses state to do an additional check

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

No branches or pull requests

2 participants