Does Dev.to not support the <video> element?

twitter logo ・1 min read

I created an article (from Markdown) that includes <video> elements. The video files are hosted on my own website.

When I save the post, the <video> elements lose their attributes (controls and playsinline) and the videos appear too large (there is no max-width: 100% style).

Does this mean that Dev.to does not support the <video> element?

twitter logo DISCUSS (2)
markdown guide
 

We do not. But that’s an interesting idea. I honestly hadn’t thought of natively supporting video raw.

We have various types of video support, but not this.

There are UX concerns in supporting the tag depending on implementation but if folks want to chat through some of those things here in the comments, it will all be taken into consideration.

 

I think if you can guide users to provide:

  • a poster image
  • a caption file
  • a good video format

… then generating the HTML or providing cut-n-paste code can be straightforward. I would rather see a native player than most of the third-party (generally inaccessible) options out there.

Classic DEV Post from Dec 17 '18

Who's looking for open source contributors? (Dec 17th edition)

Find something to work on or promote your project here. Please shamelessly pro...

Šime Vidas profile image

Customize your DEV feed to keep up with the technologies you care about.

Get Started