Jquery plugin – embedyt

Embedyt – a jquery plugin for embedding youtube video with lazy loading approach.

How Jquery plugin – embedyt works

  1. It only loads one video image from youtube and renders a play button on it.
  2. Once user clicks on the play button, video is loaded.
  3. For fancier button, you can change the javascript code accordingly.

Sample usage

jQuery(function () {
  jQuery("div.youtubeembed").each(function (index) {
    jQuery(this).embedyt(jQuery(this).attr('youid'));
  });
});

Source code

Github link: https://github.com/pkjain/embedyt

License

GPL