xrange-generator
v1.0.3
Published
xrange-generator for JS
Downloads
2
Readme
xrange-generator
xrange-generator for JS
Usage
Install package:
yarn add xrange-generator
Start xRanging and take care of the infinity produced by the generators if you provide no end-parameter.
import xrange from 'xrange-generator';
xrange(); // -> [0, 1, 2, 3, 4, 5, ...]
xrange(40); // -> [40, 41, 42, ...]
xrange(40, undefined, 5); // -> [40, 45, 50, ...]
xrange(5, 12, 3); // -> [5, 8, 11]
xrange(100, 90, 3); // -> [100, 97, 94, 91]
Dev
Lint
Based on eslint and extending the Airbnb-Style Guide.
yarn run lint
Test
By using Jest
yarn run test
Build
yarn run build