MCPcopy Create free account
hub / github.com/freecodexyz/free-code / useStats

Function useStats

src/context/stats.tsx:157–163  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

155 return t4;
156}
157export function useStats() {
158 const store = useContext(StatsContext);
159 if (!store) {
160 throw new Error("useStats must be used within a StatsProvider");
161 }
162 return store;
163}
164export function useCounter(name) {
165 const $ = _c(3);
166 const store = useStats();

Callers 4

useCounterFunction · 0.85
useGaugeFunction · 0.85
useTimerFunction · 0.85
useSetFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected