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

React 18: "VIDEOJS: WARN: The element supplied is not included in the DOM" #7753

Closed
osmarbento-AWS opened this issue May 9, 2022 · 2 comments

Comments

@osmarbento-AWS
Copy link

Description

I'm trying to migrate my app to react 18, as described in https://reactjs.org/blog/2022/03/08/react-18-upgrade-guide.html
But after the upgrade the playerjs is not loaded in the DOM anymore.

Steps to reproduce

Explain in detail the exact steps necessary to reproduce the issue.

  1. create a new react app
    npx create-react-app my-app

  2. Change the index.js to Create root as per react version 18

  import ReactDOM from "react-dom/client";
  const root = ReactDOM.createRoot(document.getElementById("root"));
  root.render(
    <React.StrictMode>
      <App />
    </React.StrictMode>
  );
  1. Implement videojs as per https://videojs.com/guides/react/

Results:

Browser responds:
"VIDEOJS: WARN: The element supplied is not included in the DOM"

Expected

videojs loaded dispose()

Actual

Please describe what actually happened.

Error output

image

Additional Information

Please include any additional information necessary here. Including the following:

versions

videojs 1.18.1

node v16.11.1

npm 8.5.0

react 18

What browser are you using?
Chrome

What operating system are you using?
macOS

@welcome
Copy link

welcome bot commented May 9, 2022

👋 Thanks for opening your first issue here! 👋

If you're reporting a 🐞 bug, please make sure you include steps to reproduce it. We get a lot of issues on this repo, so please be patient and we will get back to you as soon as we can.
To help make it easier for us to investigate your issue, please follow the contributing guidelines.

@mister-ben
Copy link
Contributor

mister-ben commented May 10, 2022

Dupe of #7746, appreciate comment on the possible approach in the comment there.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Jul 10, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants