# @addasoft/timespan

> format milliseconds as human readable strings

Latest version **1.1.6** (published 2025-06-16) · MIT license · 0 weekly downloads

## Install

```sh
npm install @addasoft/timespan
pnpm add @addasoft/timespan
yarn add @addasoft/timespan
bun add @addasoft/timespan
```

## Health

**Score 45/100 (D)** — status: stable.

Positive: esm support; no vulnerabilities; high maintenance score.

Warnings: low downloads; no types.

Negative: stale.

## Facts

| | |
|---|---|
| Version | 1.1.6 |
| Published | 2025-06-16 |
| First published | 2022-11-14 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | ESM + CommonJS |
| Dependencies | 1 |
| Unpacked size | 7.1 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 0 |
| Author | Lucien Immink |
| Maintainers | arielext |

## Links

- npm: https://www.npmjs.com/package/@addasoft/timespan
- Repository: https://github.com/lucienimmink/timespan.js
- Homepage: https://github.com/lucienimmink/timespan.js#readme
- Issues: https://github.com/lucienimmink/timespan.js/issues
- npm.io page: https://npm.io/package/@addasoft/timespan

## Dependencies (1)

- [vite](https://npm.io/package/vite.md) ^6.0.0

## Recent versions

- 1.1.6 (latest) — 2025-06-16
- 1.1.5 — 2025-03-15
- 1.1.4 — 2024-06-04
- 1.1.3 — 2024-06-04
- 1.1.2 — 2024-06-04
- 1.1.1 — 2024-04-05
- 1.1.0 — 2023-02-08
- 1.0.3 — 2022-11-14
- 1.0.2 — 2022-11-14
- 1.0.1 — 2022-11-14
- 1.0.0 — 2022-11-14

## README

# @addasoft/timespan

Format milliseconds as human-readable strings.

## Install

```bash
npm install @addasoft/timespan
```

## Use

```javascript
import timespan from '@addasoft/timespan';

const time_in_ms = 1000;
console.log(timespan(time_in__ms));
// '00:01'

const hour_in_ms = 1000 * 60 * 60;
console.log(timespan(hour_in_ms));
// '01:00:00'

const humanized_hour = 1000 * 60 * 60;
console.log(timespan(humanized_hour, true));
// '1 hr'
```

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