lambda-live-debugger
Version:
Debug Lambda functions locally like it is running in the cloud
16 lines (15 loc) • 396 B
JavaScript
export class SmithyMessageEncoderStream {
options;
constructor(options) {
this.options = options;
}
[Symbol.asyncIterator]() {
return this.asyncIterator();
}
async *asyncIterator() {
for await (const chunk of this.options.inputStream) {
const payloadBuf = this.options.serializer(chunk);
yield payloadBuf;
}
}
}