MCPcopy Index your code
hub / github.com/react/react / Parent

Function Parent

packages/react-dom/src/__tests__/ReactDOMUseId-test.js:961–968  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

959 // and sibling counters not the initial one
960 it('does not forget it mounted an id when re-rendering in dev', async () => {
961 function Parent() {
962 const id = useId();
963 return (
964 <div>
965 {id} <Child />
966 </div>
967 );
968 }
969 function Child() {
970 const id = useId();
971 return <div>{id}</div>;

Callers

nothing calls this directly

Calls 1

useIdFunction · 0.50

Tested by

no test coverage detected