nx-mesh
Version:
GraphQL Mesh support for Nx
22 lines • 646 B
JavaScript
;
Object.defineProperty(exports, "__esModule", { value: true });
exports.runTasksInSerial = void 0;
const tslib_1 = require("tslib");
/**
* Run Generator async tasks in priority order.
*
* @param tasks - An array of generator tasks, listed in priority order.
* @returns
*/
const runTasksInSerial = (...tasks) => () => tslib_1.__awaiter(void 0, void 0, void 0, function* () {
for (const task of tasks) {
if (task instanceof Promise) {
yield task();
}
else {
task();
}
}
});
exports.runTasksInSerial = runTasksInSerial;
//# sourceMappingURL=run-tasks-in-serial.js.map