ordered-regions
1.1.0 • Public • Published ordered-regions
submit out of order objects and receive that data ordered sequentially and/or in groups
install
$ npm install ordered-regions
usage
const OrderedRegions = require("../ordered-regions");
const TOTAL = 32;
const or = OrderedRegions({
total: TOTAL,
groups: 8
});
or.onEach((item) => {
console.log('item recevied in order');
});
or.onGroup((items) => {
console.log('ordered group of items recevied');
});
or.onComplete(() => {
console.log('finished ordering items');
});
for (let i = TOTAL; i >= 0; i--) {
or.submit({id: i});
}
Versions
Version | Downloads (Last 7 Days) | Tag |
---|
1.1.0 | 2 | latest |
Version History
Version | Downloads (Last 7 Days) | Published |
---|
1.1.0 | 2 | |
1.0.0 | 0 | |
Package Sidebar
Install
Weekly Downloads