react-count-until
v1.0.5
Published
count down to time
Downloads
15
Maintainers
Readme
React Count Until
Count down until the given time
Installation
Install react-countdown-until with npm
npm install react-countdown-until
Usage/Examples
import CountDown from "react-countdown-until";
function App() {
return (
<>
{/* returns in format yyy:MM:dd:HH:mm:ss */}
<CountUntil />
{/* or */}
<CountUntil date={new Date("2025-01-01")} />
</>
);
}
API Reference
| Parameter | Type | Description | Default |
| :--------------- | :-------- | :------------------------------------------ | :----------------- |
| date
| Date
| Optional. A future Date object | null
|
| className
| string
| Optional. Class names for root div | 'flex font-mono'
|
| requireLabels
| boolean
| Optional. Display locales as labels | false
|
| seperator
| string
| Optional. Seperator between timer parts | ':'
|
| displayYears
| boolean
| Optional. To display years part | true
|
| displayMonths
| boolean
| Optional. To display months part | true
|
| displaydays
| boolean
| Optional. To display days part | true
|
| displayHours
| boolean
| Optional. To display hours part | true
|
| displayMinutes
| boolean
| Optional. To display minutes part | true
|
| displaySeconds
| boolean
| Optional. To display seconds part | true
|