SIGN IN SIGN UP

[Flight] Allow overriding `request.timeOrigin` via `options.startTime` (#35598)

Currently, IO that finished before the request started is not considered
IO:

https://github.com/facebook/react/blob/6a0ab4d2dd62dfdf8881ba1c3443c6d5acedc871/packages/react-server/src/ReactFlightServer.js#L5338-L5343
This leads to loss of debug info when a flight stream is deserialized
and serialized again.
We can solve this by allowing "when the the request started" to be set
to a point in the past, when the original stream started by doing

```js
const startTime = performance.now() + performance.timeOrigin
// ... stuff happens and time passes...
ReactServer.renderToReadableStream(..., { startTime })
```
J
Janka Uryga committed
b1533b034ee5e38e825fe20d789f2e83ede163ad
Parent: 5dad2b4
Committed by GitHub <noreply@github.com> on 2/3/2026, 2:29:51 PM