npm.io
1.1.2 • Published 9 months ago

@whitewizard/countdown

Licence
ISC
Version
1.1.2
Deps
1
Size
9 kB
Vulns
0
Weekly
0

Countdown Vue component

Usage:

  • import Countdown from @whitewizard/countdown
  • Implements an unnamed slot to display something inside component.
  • Root element gets 'countdown-ended' class when countdown end is reached.
  • Emits 'countDownEnd' event with root HTML element as event.el
    • Event usage: <Countdown @countDownEnd="myHandler" />
Props:
  • format {String}. String representing units to display, separated by colons. Default: hours:minutes:seconds
  • separators {String}. Text to show between countdown data elements, separated by colons. Default: h:m:s
  • end {String} RFC 3339 datetime string. Represents countdown end time. Required. (RFC 3339)