MCPcopy
hub / github.com/facebook/react / App

Function App

packages/react-reconciler/src/__tests__/ReactActWarnings-test.js:157–161  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

155 it('warns about unwrapped updates only if environment flag is enabled', async () => {
156 let setState;
157 function App() {
158 const [state, _setState] = useState(0);
159 setState = _setState;
160 return <Text text={state} />;
161 }
162
163 const root = ReactNoop.createRoot();
164 root.render(<App />);

Callers

nothing calls this directly

Calls 7

withActEnvironmentFunction · 0.85
startTransitionFunction · 0.85
resolveTextFunction · 0.70
renderMethod · 0.65
useStateFunction · 0.50
actFunction · 0.50
assertLogFunction · 0.50

Tested by

no test coverage detected