In this tutorial, we will learn iOS 7 style switches for checkboxes example using switchery JS
use bellow path of CDN:
CDN:
https://cdnjs.cloudflare.com/ajax/libs/switchery/0.8.2/switchery.min.css
https://cdnjs.cloudflare.com/ajax/libs/switchery/0.8.2/switchery.min.js
Example:
<!DOCTYPE html>
<html>
<head>
<title>ISOtype switching animation example using switchery JS</title>
<script src="https://ajax.googleapis.com/ajax/libs/jquery/1.6.1/jquery.min.js" type="text/javascript"></script>
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/switchery/0.8.2/switchery.min.css">
<script src="https://cdnjs.cloudflare.com/ajax/libs/switchery/0.8.2/switchery.min.js
" type="text/javascript"></script>
</head>
<body>
<input type="checkbox" class="js-switch" checked />
<script type="text/javascript">
var elem = document.querySelector('.js-switch');
var init = new Switchery(elem);
</script>
</body>
</html>
May this example help you.