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

Question: what's the best way to pass custom attributes to video element? #2

Open
manfromanotherland opened this issue Sep 3, 2019 · 1 comment

Comments

@manfromanotherland
Copy link

Hi. First of all, thanks for writing this plugin, really cool and it is perfectly integrated with filepond!

I have a question regarding adding custom attributes to video element. Right now the video element comes like this:

<video
  controls="true"
  src="source.mp4"
></video>

But it would be great to be able set controls to false or add other ones, such as autoplay, crossorigin, or controlslist (see MDN web docs for more options.):

<video
  controls="true"
  controlslist="nodownload nofullscreen noremoteplay"
  autoplay="true"
  src="source.mp4"
></video>

Any suggestions on how to do that?

Thanks!

@nielsboogaard
Copy link
Owner

Hi, thanks for using the plugin, good to hear!

About adding custom attributes to the video element: best is to provide those as configuration options. For examples you can look at the already existing configuration options, see index.js#60.

If you could create a PR for this, I'd happy to review and merge it. Else I might have a look myself, but it might take a while before I have time to dive into this.

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