Yields numeric range between 0.0-1.0.
// Yields: [0, 0.2, 0.4, 0.6, 0.8, 1]const a = [...numericPercent(0.2)];// Repeating flag set to true:for (const v of numericPercent(0.2, true)) { // Infinite loop. V loops back to 0 after hitting 1} Copy
// Yields: [0, 0.2, 0.4, 0.6, 0.8, 1]const a = [...numericPercent(0.2)];// Repeating flag set to true:for (const v of numericPercent(0.2, true)) { // Infinite loop. V loops back to 0 after hitting 1}
If repeating is true, it loops back to 0 after reaching 1
repeating
Interval (default: 0.01, ie. 1%)
Whether generator should loop (default: false)
Start (default: 0)
End (default: 1)
Yields numeric range between 0.0-1.0.
If
repeating
is true, it loops back to 0 after reaching 1