In this exercise, you'll add code to the so that you can actually watch the videos on the page.
bodyof your HTML, create a <div> to hold the video player, either below or to the side of the list, and give it an id.
scripttag that you were working in before, create a
thumbnailify()function that takes a single argument.
forloop into that
<a>, rather than an array of elements.
forloop so that it occurs after you define
thumbnailify()from inside your
thumbnailify()function, add a click listener to the link. We recommend using a named function for the callback (not an anonymous function). Put a
console.loginside the callback to make sure it works.
.html(), or other jQuery method of your choice to assemble and insert the embedded video element.
Make sure that you use your browser developer tools to make debugging easier while working on this. Check for errors, and use console.log() to figure out how far your code makes it, and what the values of your variables are along the way.