hjemmesidekongen/ai/expo-data-fetching
- community
Checking that the SKILL.md file is still in the repository.
Data fetching in Expo — fetch, React Query, SWR, offline support, and caching strategies
Install
npx vskill@latest install hjemmesidekongen/ai/expo-data-fetchingSKILL.md
Expo Data Fetching
React Native has fetch built in — but raw fetch in useEffect creates unreliable, verbose patterns. React Query is the standard for server state in Expo apps.
React Query Setup
Wrap the root layout in QueryClientProvider. Set staleTime, retry, and refetchOnWindowFocus: false in defaults — mobile apps don't have browser windows, so the default focus refetch fires unexpectedly without this.
Query and Mutation
Key Rules
- Use React Query for all remote server state. Local UI state stays in
useState. - Define query keys as typed constants — never inline strings across files.
- Always handle
isLoadinganderrorbefore accessingdata. - Set
staleTimein defaults to reduce unnecessary refetches on screen focus. - For offline-first, persist the query cache with MMKV or AsyncStorage.
See references/process.md for SWR patterns, offline strategies (AsyncStorage, MMKV, WatermelonDB), optimistic updates, infinite queries, cache persistence, error handling, type-safe fetching, and anti-patterns.
Security
- Security scanPassed, 90 of 100Pattern checks on the skill's files.
- Model reviewPassed
Quality evaluation
- Task evaluationNot runNo evaluation yet. Run one in Skill Studio.
Source
- SKILL.md in the repositoryCheckingplugins/smedjen/skills/expo-data-fetching/SKILL.md
Popularity
- 7-day trend score
- 5
Not refreshed yet.
Works with
Any agent vskill installs to: 56 targets in all. These 39 have a page on this site.
- Claude Code
- Cursor
- GitHub Copilot
- Windsurf
- Codex
- Gemini CLI
- Cline
- Amp
- Roo Code
- Goose
- Continue
- Kilo Code
- Junie
- Trae
- OpenHands
- Qwen Code
- AI Agent
- Tabnine Chat
- Sourcegraph Cody
- Amazon Q
- Firebase Genkit
- Sweep
- Devin
- Phind
- Mentat
- Claude Desktop
- Aider
- GPT Pilot
- Plandex
- bolt.new
- v0
- Replit Agent
- Anse
- TypingMind
- BetterChatGPT
- LibreChat
- Warp AI
- Pieces
- Fig AI
Embed badge
[](https://verified-skill.com/skills/hjemmesidekongen/ai/expo-data-fetching)