# react-human-timer

> React component wrapper for human-timer: tiny, human readable timer with no external dependencies. Specify the duration in seconds, add callbacks to timer ticks and end, stop it at any moment.

Latest version **1.0.1** (published 2018-12-04) · MIT license · 0 weekly downloads

## Install

```sh
npm install react-human-timer
pnpm add react-human-timer
yarn add react-human-timer
bun add react-human-timer
```

## Health

**Score 15/100 (F)** — status: abandoned.

Positive: no vulnerabilities.

Warnings: low downloads; no types; no esm support.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 1.0.1 |
| Published | 2018-12-04 |
| First published | 2018-12-03 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 2 |
| Unpacked size | 12.7 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 0 |
| Author | ol-web |
| Maintainers | ol-web |
| Keywords | timer, countdown, human-timer, react-human-timer, react-timer, react-countdown, react |

## Links

- npm: https://www.npmjs.com/package/react-human-timer
- Repository: https://github.com/oL-web/react-human-timer
- Homepage: https://github.com/oL-web/react-human-timer#readme
- Issues: https://github.com/oL-web/react-human-timer/issues
- npm.io page: https://npm.io/package/react-human-timer

## Dependencies (2)

- [prop-types](https://npm.io/package/prop-types.md) ^15.6.2
- [human-timer](https://npm.io/package/human-timer.md) ^1.0.0

## Alternatives

- [mobx-react](https://npm.io/package/mobx-react.md) — 2.8M weekly downloads
- [rc-tree](https://npm.io/package/rc-tree.md) — 2.6M weekly downloads
- [@react-oauth/google](https://npm.io/package/@react-oauth/google.md) — 1.3M weekly downloads
- [@wagmi/connectors](https://npm.io/package/@wagmi/connectors.md) — 877.0K weekly downloads
- [vee-validate](https://npm.io/package/vee-validate.md) — 836.4K weekly downloads

## Recent versions

- 1.0.1 (latest) — 2018-12-04
- 1.0.0 — 2018-12-03

## README

# react-human-timer

React component wrapper for human-timer: tiny, human readable timer with no external dependencies. Specify the duration in seconds, add callbacks to timer ticks and end, stop it at any moment.

[Here's the main human-timer library](https://github.com/oL-web/human-timer)

* * *

### Installation:

`npm install --save react-human-timer`  

Test

`npm run test`  

* * *

### Usage:

```javascript
 <HumanTimer 
    onTick={(timer) => console.log("tick", timer)} 
    onEnd={(timer) => console.log("end", timer)} 
    active={true} // set to false to pause the timer, default is true
    zeroes={false}  // won't turn 5 mins into 05 mins, default is true
    seconds={7200} // 2 hour long duration
>
    {
        (timer) => (
            <div>
                <p>Hours: {timer.hours}</p>
                <p>Minutes: {timer.minutes}</p>
                <p>Seconds: {timer.seconds}</p>
            </div>
        )
    }
</HumanTimer>
```

* * *

### Is there something wrong?

Please tell me!

---
_Source: https://npm.io/package/react-human-timer · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
