We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent a1d1145 commit 2bdc07cCopy full SHA for 2bdc07c
packages/graphql-yoga/__tests__/utilities.ts
@@ -4,7 +4,10 @@ import { Repeater } from '@repeaterjs/repeater';
4
/** Parse SSE event stream and yield data pieces. */
5
export function eventStream<TType = unknown>(source: ReadableStream<Uint8Array>) {
6
return new Repeater<TType>(async (push, end) => {
7
- const cancel: Promise<{ done: true }> = end.then(() => ({ done: true }));
+ const cancel: Promise<{ done: true; value: undefined }> = end.then(() => ({
8
+ done: true,
9
+ value: undefined,
10
+ }));
11
const iterable = source[Symbol.asyncIterator]();
12
13
// eslint-disable-next-line no-constant-condition
0 commit comments