Skip to content

Commit

Permalink
Add useOptimistic to devtools shell
Browse files Browse the repository at this point in the history
  • Loading branch information
Sebastian Silbermann committed Feb 2, 2024
1 parent fdb4acb commit fc9c2ab
Showing 1 changed file with 2 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ import {
useContext,
useDebugValue,
useEffect,
useOptimistic,
useState,
} from 'react';

Expand Down Expand Up @@ -73,6 +74,7 @@ function FunctionWithHooks(props: any, ref: React$Ref<any>) {
const [count, updateCount] = useState(0);
// eslint-disable-next-line no-unused-vars
const contextValueA = useContext(ContextA);
useOptimistic<number, mixed>(1);

// eslint-disable-next-line no-unused-vars
const [_, __] = useState(object);
Expand Down

0 comments on commit fc9c2ab

Please sign in to comment.