Skip to content

Latest commit

 

History

History

odo-responsive-images

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Odo Responsive Images

Native responsive images with deferred loading.

Install

npm install @odopod/odo-responsive-images --save

Quick Start

<div class="odo-responsive-img">
  <!--[if IE 9]><video style="display: none;"><![endif]-->
  <source srcset="https://source.unsplash.com/category/buildings/800x400" media="(min-width: 992px)">
  <source srcset="https://source.unsplash.com/category/technology/600x300" media="(min-width: 768px)">
  <source srcset="https://source.unsplash.com/category/nature/400x200">
  <!--[if IE 9]></video><![endif]-->
  <img alt="picture 1 description">
  <noscript>
    <img src="https://source.unsplash.com/category/nature/400x200" alt="picture 1 description">
  </noscript>
</div>

Visit the Odo component directory for demos, code examples, and documentation.