Skip to content

Commit f57283f

Browse files
committed
Wire up public facing option
1 parent 7ac3a2e commit f57283f

File tree

11 files changed

+44
-11
lines changed

11 files changed

+44
-11
lines changed

packages/react-server-dom-esm/src/client/ReactFlightDOMClientBrowser.js

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -52,6 +52,7 @@ export type Options = {
5252
findSourceMapURL?: FindSourceMapURLCallback,
5353
replayConsoleLogs?: boolean,
5454
environmentName?: string,
55+
startTime?: number,
5556
};
5657

5758
function createDebugCallbackFromWritableStream(
@@ -103,7 +104,9 @@ function createResponseFromOptions(options: void | Options) {
103104
__DEV__ && options && options.environmentName
104105
? options.environmentName
105106
: undefined,
106-
undefined,
107+
__DEV__ && options && options.startTime != null
108+
? options.startTime
109+
: undefined,
107110
debugChannel,
108111
);
109112
}

packages/react-server-dom-esm/src/client/ReactFlightDOMClientNode.js

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -57,6 +57,7 @@ export type Options = {
5757
findSourceMapURL?: FindSourceMapURLCallback,
5858
replayConsoleLogs?: boolean,
5959
environmentName?: string,
60+
startTime?: number,
6061
// For the Node.js client we only support a single-direction debug channel.
6162
debugChannel?: Readable,
6263
};
@@ -112,7 +113,9 @@ function createFromNodeStream<T>(
112113
__DEV__ && options && options.environmentName
113114
? options.environmentName
114115
: undefined,
115-
undefined,
116+
__DEV__ && options && options.startTime != null
117+
? options.startTime
118+
: undefined,
116119
debugChannel,
117120
);
118121

packages/react-server-dom-parcel/src/client/ReactFlightDOMClientBrowser.js

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -129,7 +129,9 @@ function createResponseFromOptions(options: void | Options) {
129129
__DEV__ && options && options.environmentName
130130
? options.environmentName
131131
: undefined,
132-
undefined,
132+
__DEV__ && options && options.startTime != null
133+
? options.startTime
134+
: undefined,
133135
debugChannel,
134136
);
135137
}
@@ -206,6 +208,7 @@ export type Options = {
206208
temporaryReferences?: TemporaryReferenceSet,
207209
replayConsoleLogs?: boolean,
208210
environmentName?: string,
211+
startTime?: number,
209212
};
210213

211214
export function createFromReadableStream<T>(

packages/react-server-dom-parcel/src/client/ReactFlightDOMClientEdge.js

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -79,6 +79,7 @@ export type Options = {
7979
temporaryReferences?: TemporaryReferenceSet,
8080
replayConsoleLogs?: boolean,
8181
environmentName?: string,
82+
startTime?: number,
8283
// For the Edge client we only support a single-direction debug channel.
8384
debugChannel?: {readable?: ReadableStream, ...},
8485
};
@@ -107,7 +108,9 @@ function createResponseFromOptions(options?: Options) {
107108
__DEV__ && options && options.environmentName
108109
? options.environmentName
109110
: undefined,
110-
undefined,
111+
__DEV__ && options && options.startTime != null
112+
? options.startTime
113+
: undefined,
111114
debugChannel,
112115
);
113116
}

packages/react-server-dom-parcel/src/client/ReactFlightDOMClientNode.js

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -52,6 +52,7 @@ export type Options = {
5252
encodeFormAction?: EncodeFormActionCallback,
5353
replayConsoleLogs?: boolean,
5454
environmentName?: string,
55+
startTime?: number,
5556
// For the Node.js client we only support a single-direction debug channel.
5657
debugChannel?: Readable,
5758
};
@@ -103,7 +104,9 @@ export function createFromNodeStream<T>(
103104
__DEV__ && options && options.environmentName
104105
? options.environmentName
105106
: undefined,
106-
undefined,
107+
__DEV__ && options && options.startTime != null
108+
? options.startTime
109+
: undefined,
107110
debugChannel,
108111
);
109112

packages/react-server-dom-turbopack/src/client/ReactFlightDOMClientBrowser.js

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,6 +51,7 @@ export type Options = {
5151
findSourceMapURL?: FindSourceMapURLCallback,
5252
replayConsoleLogs?: boolean,
5353
environmentName?: string,
54+
startTime?: number,
5455
};
5556

5657
function createDebugCallbackFromWritableStream(
@@ -102,7 +103,9 @@ function createResponseFromOptions(options: void | Options) {
102103
__DEV__ && options && options.environmentName
103104
? options.environmentName
104105
: undefined,
105-
undefined,
106+
__DEV__ && options && options.startTime != null
107+
? options.startTime
108+
: undefined,
106109
debugChannel,
107110
);
108111
}

packages/react-server-dom-turbopack/src/client/ReactFlightDOMClientEdge.js

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -79,6 +79,7 @@ export type Options = {
7979
findSourceMapURL?: FindSourceMapURLCallback,
8080
replayConsoleLogs?: boolean,
8181
environmentName?: string,
82+
startTime?: number,
8283
// For the Edge client we only support a single-direction debug channel.
8384
debugChannel?: {readable?: ReadableStream, ...},
8485
};
@@ -109,7 +110,9 @@ function createResponseFromOptions(options: Options) {
109110
__DEV__ && options && options.environmentName
110111
? options.environmentName
111112
: undefined,
112-
undefined,
113+
__DEV__ && options && options.startTime != null
114+
? options.startTime
115+
: undefined,
113116
debugChannel,
114117
);
115118
}

packages/react-server-dom-turbopack/src/client/ReactFlightDOMClientNode.js

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -60,6 +60,7 @@ export type Options = {
6060
findSourceMapURL?: FindSourceMapURLCallback,
6161
replayConsoleLogs?: boolean,
6262
environmentName?: string,
63+
startTime?: number,
6364
// For the Node.js client we only support a single-direction debug channel.
6465
debugChannel?: Readable,
6566
};
@@ -114,7 +115,9 @@ function createFromNodeStream<T>(
114115
__DEV__ && options && options.environmentName
115116
? options.environmentName
116117
: undefined,
117-
undefined,
118+
__DEV__ && options && options.startTime != null
119+
? options.startTime
120+
: undefined,
118121
debugChannel,
119122
);
120123

packages/react-server-dom-webpack/src/client/ReactFlightDOMClientBrowser.js

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,6 +51,7 @@ export type Options = {
5151
findSourceMapURL?: FindSourceMapURLCallback,
5252
replayConsoleLogs?: boolean,
5353
environmentName?: string,
54+
startTime?: number,
5455
};
5556

5657
function createDebugCallbackFromWritableStream(
@@ -102,7 +103,9 @@ function createResponseFromOptions(options: void | Options) {
102103
__DEV__ && options && options.environmentName
103104
? options.environmentName
104105
: undefined,
105-
undefined,
106+
__DEV__ && options && options.startTime != null
107+
? options.startTime
108+
: undefined,
106109
debugChannel,
107110
);
108111
}

packages/react-server-dom-webpack/src/client/ReactFlightDOMClientEdge.js

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -79,6 +79,7 @@ export type Options = {
7979
findSourceMapURL?: FindSourceMapURLCallback,
8080
replayConsoleLogs?: boolean,
8181
environmentName?: string,
82+
startTime?: number,
8283
// For the Edge client we only support a single-direction debug channel.
8384
debugChannel?: {readable?: ReadableStream, ...},
8485
};
@@ -109,7 +110,9 @@ function createResponseFromOptions(options: Options) {
109110
__DEV__ && options && options.environmentName
110111
? options.environmentName
111112
: undefined,
112-
undefined,
113+
__DEV__ && options && options.startTime != null
114+
? options.startTime
115+
: undefined,
113116
debugChannel,
114117
);
115118
}

0 commit comments

Comments
 (0)