Skip to content

svr93/custom-clock

Repository files navigation

<custom-clock> Web Component

Simple clock component built with SVG & CSS Animations

clock

Browser support

Tested in Chrome 70, Firefox 64, Safari 12.0. You should use Array.prototype.flatMap polyfill for older browsers.

Usage

import { CustomClockComponent } from 'custom-clock'
customElements.define('custom-clock', CustomClockComponent)
<custom-clock size="100px" stroke-color="#536dfe"></custom-clock>

You can use existing JavaScript & TypeScript definitions via special import:

import 'custom-clock/dist/src/global-declarations'

Please see the discussion about predefined names.

Attributes

  • size (CSS value for clock width & height)
  • stroke-color (CSS value)

About

Simple clock component built with SVG & CSS Animations

Resources

License

Stars

Watchers

Forks

Packages

No packages published