countdown-man
v0.1.3
Published
## Example: ```javascript const endtime = 'Wed Sep 24 2020 17:00:00 GMT+0800' <count-down :end-time="new Date(endtime)" > <template v-slot="{ days, hours, minutes, seconds }">
Readme
App
Example:
const endtime = 'Wed Sep 24 2020 17:00:00 GMT+0800'
<count-down :end-time="new Date(endtime)" >
<template v-slot="{ days, hours, minutes, seconds }">
</template>
</count-down>Slots
| Name | Description |
| --------- | ---------------------------------------------- |
| default | the slot provide days, hours, minutes, seconds |
Props
| Name | Type | Description |
| ---------- | ------ | ------------ |
| end-time | Date | endting time |
Data
| Name | Type | Description | Initial value |
| --------- | --------- | ----------- | ------------- |
| days | number | | 0 |
| hours | number | | 0 |
| minutes | number | | 0 |
| seconds | number | | 0 |
| timeUp | boolean | | false |
| timer | any | | null |
Events
| Name | Description |
| ------- | ----------------------------------- |
| onend | what happen when the count down end |
Methods
makeTimer()
Syntax
makeTimer(): voidonend()
Syntax
onend(): void