Skip to content

ryzmae/msx

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

msx

NPM Downloads

A minmalistic ms conversion library

Examples

Use the following command to install the msxlib package via npm:

npm install msxlib

Once installed, you can import and use the library in your code:

import msx from "msxlib";

console.log(MSX.parse("1ms")); // 1
console.log(MSX.parse("1s")); // 1000
console.log(MSX.parse("1m")); // 60000
console.log(MSX.parse("1h")); // 3600000
console.log(MSX.stringify(1)); // 1.00ms

For more information on how to use the msxlib package, please refer to the documentation.

NOTE: doesn't work with javascript only typescript at the moment

Packages

No packages published