Simple Analog Clock With jQuery And CSS3 - jsRapClock

Simple Analog Clock With jQuery And CSS3 - jsRapClock
File Size: 4.46 KB
Views Total:
Last Update:
Publish Date:
Official Website: Go to website
License: MIT
   

jQuery jsRapClock is a simple, lightweight jQuery clock plugin which makes it easy to render a responsive Analog Clock on the web application using CSS3 2D transforms. No canvas and SVG used.

How to use it:

1. Create a container in which you want to render the analog clock.

<div id="demo"></div>

2. Download and insert the jQuery jsRapClock plugin's files after jQuery (slim build).

<link rel="stylesheet" href="jsRapClock.css">
<script src="https://code.jquery.com/jquery-3.3.1.slim.min.js" 
        integrity="sha384-q8i/X+965DzO0rT7abK41JStQIAqVgRVzpbzo5smXKp4YfRvH+8abtTE1Pi6jizo" 
        crossorigin="anonymous">
</script>
<script src="jsRapClock.js"></script>

3. Call the function on document ready to render a default analog clock in the container.

$(function(){

  $('#demo').jsRapClock();

});

4. Add a caption to the analog clock.

$(function(){

  $('#demo').jsRapClock({
    caption: 'jQueryScript'
  });

});

5. More configuration options.

$(function(){

  $('#demo').jsRapClock({
    shiftH: 1,
    shiftM: 30,
    shiftS:0
  });

});

Changelog:

2019-05-17


This awesome jQuery plugin is developed by Thibor. For more Advanced Usages, please check the demo page or visit the official website.