/ Image Comparison

JQuery slider plugin for before vs after comparison

JQuery slider plugin for before vs after comparison

jquery-before-after-slider

jquery plugin, before vs after comparison.

JQuery slider plugin for "before vs after" comparison.

Made with

Html
Css
Javascript

Author

hanumanum

Instalation

Step 1

Include jquery and plugin file

 <script src="node_modules/jquery/dist/jquery.js"></script>
 <script src="jquery-before-after-slider.min.js"></script>

Step 2

Create wrapper for plugin

     <div id="slider">
    </div>

Step 3

Configure plugin and run it

var config = {
          "width": "700px",
          "height": "600px",
          "start": "25%",
          "firstImage": "images/IMG_6474_1.jpg",
          "secondImage": "images/IMG_6474_2.jpg"
      }

$(document).ready(function() {
    $("#slider").hanBeforeAfterSlider(config);
});

GitHub