Skip to content
This repository was archived by the owner on May 3, 2020. It is now read-only.

The jQuery plugin for allowing you to switch images based on screen size using data-attributes.

Notifications You must be signed in to change notification settings

rakuishi/jquery-responsive-image

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

8 Commits
 
 
 
 
 
 
 
 

Repository files navigation

jquery-responsive-image

The jQuery plugin for allowing you to switch images based on screen size using data-attributes.

Usage

<img src="images/mobile.png"
     data-mobile="images/mobile.png"
     data-phablet="images/phablet.png"
     data-tablet="images/tablet.png"
     data-desktop="images/desktop.png"/>

<script src="//code.jquery.com/jquery-1.11.2.min.js"></script>
<script src="../jquery.responsive-image.js"></script>
<script type="text/javascript">
  $("body").responsiveImage({
    mobile : 400,
    phablet: 550,
    tablet : 750,
    desktop: 1000,
  });
</script>

License

MIT License

About

The jQuery plugin for allowing you to switch images based on screen size using data-attributes.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published