Last active
March 27, 2019 16:02
-
-
Save dghez/94ad640528d859b011f72a750572b4be to your computer and use it in GitHub Desktop.
Return random values, float or int
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import RN from 'random-number'; | |
let rand = RN.generator(); | |
let randInt = (min, max) => { | |
return rand(min, max, true); | |
}; | |
let randFloat = (min, max) => { | |
return rand(min, max, false); | |
}; | |
export { randInt, randFloat }; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment