Hook returning instance of DXOS client.
Requires ClientContext to be set via ClientProvider.
Under a suspend ClientProvider the context is available before client.initialize()
completes; this hook then suspends (throws the initialization promise) so any component
depending on the client parks at its nearest Suspense boundary instead of reading an
uninitialized client.
Deliberately no timeout here: React retries a rejected thrown promise and the retry suspends
again, so a rejection loops rather than reaching an error boundary (measured: ~90 renders in
500ms). A stalled initialization is bounded once, at the app entry point, which raises it as a
fatal error instead.
Hook returning instance of DXOS client. Requires ClientContext to be set via ClientProvider.
Under a
suspendClientProvider the context is available beforeclient.initialize()completes; this hook then suspends (throws the initialization promise) so any component depending on the client parks at its nearest Suspense boundary instead of reading an uninitialized client.Deliberately no timeout here: React retries a rejected thrown promise and the retry suspends again, so a rejection loops rather than reaching an error boundary (measured: ~90 renders in 500ms). A stalled initialization is bounded once, at the app entry point, which raises it as a fatal error instead.