Welcome to the Treehouse Community

Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.

Start your free trial

HTML HTML Video and Audio (Retired) Custom Media Players Adding MediaElement.js

Danielle Teychenne
Danielle Teychenne
3,793 Points

How can I make my videos responsive without losing their height/width ratio?

How can I make my videos resize with the browser?

1 Answer

Danielle Teychenne
Danielle Teychenne
3,793 Points

Would something like fitsvids.js work with mediaelement.js? http://fitvidsjs.com/

Chris Shaw
Chris Shaw
26,676 Points

Fitvid.js should work just fine with mediaelement.js, I've seen a few examples floating around including the one below.

http://codepen.io/grappler/pen/xsgyb