npm.io
1.1.1 • Published 6 years ago

errorsparty.dev-birthdays

Licence
MIT
Version
1.1.1
Deps
0
Size
20 kB
Vulns
0
Weekly
0
DeprecatedThis package is deprecated

errorsparty.dev-birthdays

A very simple helper module to calculate a person's age.

Example:

import { BirthDate } from "errorsparty.dev-birthdays";

// compact format: yyyymmdd
const bday = BirthDate.from(20020603).age()
// -> 18
// This was written in 2020, this result will differ in 2021+