MCPcopy
hub / github.com/preactjs/preact / fn

Function fn

debug/test/browser/debug-hooks.test.jsx:44–52  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

42 }
43 }
44 const fn = () =>
45 act(() =>
46 render(
47 <Foo>
48 <App />
49 </Foo>,
50 scratch
51 )
52 );
53 expect(fn).to.throw(/Hook can only be invoked from render/);
54 });
55

Callers

nothing calls this directly

Calls 4

actFunction · 0.90
renderFunction · 0.90
useStateFunction · 0.90
fooFunction · 0.85

Tested by

no test coverage detected