MCPcopy Create free account
hub / github.com/QuarkGluonPlasma/react-course-code / Aaa

Function Aaa

context-trap/src/App4.tsx:28–38  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

26);
27
28const Aaa = () => {
29 const aaa = useStore((state) => state.aaa);
30 const setAaa = useStore(state => state.setAaa);
31
32 console.log('Aaa render...')
33
34 return <div>
35 aaa: {aaa}
36 <button onClick={() => setAaa(aaa + 1)}>加一</button>
37 </div>;
38};
39
40const Bbb = () => {
41 const bbb = useStore((state) => state.bbb);

Callers

nothing calls this directly

Calls 1

useStoreFunction · 0.50

Tested by

no test coverage detected