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

Videos do not work / wrong type for VideoItem in docs #529

Closed
alexandruantochi opened this issue Mar 11, 2023 · 2 comments · Fixed by #542
Closed

Videos do not work / wrong type for VideoItem in docs #529

alexandruantochi opened this issue Mar 11, 2023 · 2 comments · Fixed by #542
Labels

Comments

@alexandruantochi
Copy link

alexandruantochi commented Mar 11, 2023

Using

src = { url : string, type: string } will give an error:

Type '{ url: string; type: string; }' is not assignable to type 'string | (string & { url: string; type: string; })'.
  Type '{ url: string; type: string; }' is not assignable to type 'string & { url: string; type: string; }'.
    Type '{ url: string; type: string; }' is not assignable to type 'string'.(2322)

https://stackblitz.com/edit/angular-twfplh?file=src%2Fmain.ts

@alexandruantochi
Copy link
Author

Also a small sidenote, not having controls : true or autoplay: true will make the video unplayeble. Their default values are undefined.

@MurhafSousli
Copy link
Owner

Add src: [{ url: this.videoLink, type: 'video/mp4' }] as any

@MurhafSousli MurhafSousli linked a pull request Apr 23, 2023 that will close this issue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants