MCPcopy Index your code
hub / github.com/TanStack/query / usePokemonID

Function usePokemonID

examples/solid/astro/src/components/SolidApp.tsx:22–26  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

20const PokemonIdContext = createContext<() => string>()
21
22const usePokemonID = () => {
23 const id = useContext(PokemonIdContext)
24 if (!id) throw new Error('PokemonIdContext not found')
25 return id
26}
27
28const MAX_POKEMONS = 100
29

Callers 2

PokemonDetailsFunction · 0.85
SideNavFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…