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

Cannot use VideoJS 8.x with Angular #8324

Open
ghost opened this issue Jun 17, 2023 · 4 comments
Open

Cannot use VideoJS 8.x with Angular #8324

ghost opened this issue Jun 17, 2023 · 4 comments

Comments

@ghost
Copy link

ghost commented Jun 17, 2023

Hello,

I'm trying to switch over to VideoJS 8.3 at my Angular application, but sadly I cannot load the player anymore:

import videojs from 'video.js';

-> This seems to be working.

This also does not work anymore:

public player!: videojs.Player;

Why can't I access the player anymore? This currently results in the following error:

TS2724: 'videojs' has no exported member named 'Player'. Did you mean 'players'?

@renanrider
Copy link

Same here

@mg360
Copy link

mg360 commented Aug 10, 2023

Me too

@nikhilbhalwankar
Copy link

nikhilbhalwankar commented Nov 13, 2023

I was facing the same issue. However if you provide additional import as follows, it works

import Player from "video.js/dist/types/player";

@MarcoSerrano1013
Copy link

Hello friends, I don't understand why the thumbs down to @nikhilbhalwankar , he is correct with:
import Player from "video.js/dist/types/player";

Just missed commenting that the variable has to stop referencing from video.js, so it would be:
public player!: Player;

Happy coding! 👻

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

4 participants