ticktock-js
v3.1.9
Published
TickTock is a JavaScript library used to animate mechanical watches and clocks.
Downloads
29
Maintainers
Readme
TickTock JS - View Docs
TickTock JS is a library for animating and rotating SVG elements to tell the time on a clock or watch dial. It works as a parent Watch class which builds components as needed based on the user settings. These components currently include:
- Dials
- Dual Time Support (with Moment-Timezone)
- Sweeping / Jumping Seconds
- Power Reserve
- Chronograph
- Flyback
- Split-Second (Rattrapante)
- Moonphase
- Minute Repeater
- Day/Night Indicator
- Perpetual Calendar
- Day Indicator
- Retrograde Display
- Date Indicator
- Split Display
- Retrograde Display
- Month Indicator
- Retrograde Display
- Week Indicator
- Year Indicator
- Equation of Time
- Day Indicator
- Foudroyante
Getting Started
Install the ticktock-js package via the terminal.
yarn add ticktock-js --dev
npm install ticktock-js --save-dev
Include the library into your project.
const Watch = require('ticktock-js');
Then instantiate the Watch class with the settings
object.
const settings = { ... };
let demo = new Watch(settings);
Documentation
Full documentation of the TickTock functionality and API along with demos and guides can be found here.