@blueleader07/typeorm
Version:
Data-Mapper ORM for TypeScript, ES7, ES6, ES5. Supports MySQL, PostgreSQL, MariaDB, SQLite, MS SQL Server, Oracle, MongoDB databases.
19 lines (17 loc) • 536 B
JavaScript
;
Object.defineProperty(exports, "__esModule", { value: true });
exports.dynamoBatchHelper = void 0;
exports.dynamoBatchHelper = {
batch(items, batchSize) {
let position = 0;
batchSize = batchSize || 25;
const batches = [];
while (position < items.length) {
const batch = items.slice(position, position + batchSize);
batches.push(batch);
position += batchSize;
}
return batches;
},
};
//# sourceMappingURL=DynamoBatchHelper.js.map