IanRamosC / metric.js

Home Page:https://ianramosc.github.io/metric.js

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Metric.js

Lightweight easy-to-use library for unit of measurement conversion.

Metric.js

Build Status

What is love Metric?

Metric.js is a lightweight library that provides an easy way to convert units of measurement.

Installation

$ npm install --save metricjs

or

<script src="./js/metric.min.js"></script>

Usage

// If you're using node
const metric = require("metricjs")

let birthday = new Date("1995-03-01T00:00:00Z").getTime()

let age = metric.milliseconds(Date.now() - birthday).toYears() // 21.38...

You can find the full documentation here

License

MIT © Ian Ramos

About

https://ianramosc.github.io/metric.js

License:MIT License


Languages

Language:JavaScript 100.0%