ptz-math

ptz-math is a library for math operations such as random()

Usage no npm install needed!

<script type="module">
  import ptzMath from 'https://cdn.skypack.dev/ptz-math';
</script>

README

ptz-math

Build Status NPM codecov.io Dependency Status bitHound Score MIT license

Translations

pt-br en-us

ptz-math is a javascript library for math operations

Be welcome to learn, help and play!!!

Docs

Full docs

Use

Install

    npm install --save ptz-math

How to use

Get random number between 2 and 8:

    import { random } from ptz-math;

    const min = 2;
    const max = 8;
    const randomNumber = random(min, max);

Get random item from array:

    import { getRandomItem } from ptz-math;

    const list = ['a', 'b', 'c', 'd'];
    const randomItem = getRandomItem(list);

Contribute

NPM Global packages

    npm install -g ts-node babel-cli

Setup

    npm install   

Test

    npm test