Skip to content

Commit a511dc7

Browse files
authored
Error for deferred value and transition in Server Components (#20657)
1 parent fb3f63f commit a511dc7

File tree

1 file changed

+2
-6
lines changed

1 file changed

+2
-6
lines changed

packages/react-server/src/ReactFlightServer.js

+2-6
Original file line numberDiff line numberDiff line change
@@ -773,12 +773,8 @@ const Dispatcher: DispatcherType = {
773773
return callback;
774774
},
775775
useDebugValue(): void {},
776-
useDeferredValue<T>(value: T): T {
777-
return value;
778-
},
779-
useTransition(): [(callback: () => void) => void, boolean] {
780-
return [() => {}, false];
781-
},
776+
useDeferredValue: (unsupportedHook: any),
777+
useTransition: (unsupportedHook: any),
782778
getCacheForType<T>(resourceType: () => T): T {
783779
invariant(
784780
currentCache,

0 commit comments

Comments
 (0)