nghyane/vstep/mobile-data-patterns
Claude Code and agent skill by nghyane/vstep
Trust tier 3
- community
Source check pending
Checking that the SKILL.md file is still in the repository.
TanStack Query + Zustand + API integration patterns. Server state, mutations, local stores, error handling, token refresh. Load when working with data layer.
Install
npx vskill@latest install nghyane/vstep/mobile-data-patternsSKILL.md
Mobile Data Patterns
QueryClient Setup
- Global error handler: 401 → logout, else → toast/Alert
staleTime: 5 minutes— reasonable for mobileretry: false— fail fast on mobile, user can retry manually
API Client
- Key transforms: Laravel snake_case ↔ React Native camelCase
- Auto-unwrap
{ data: T }response wrapper - Auto-refresh 401 tokens via
tryRefresh()
Query Patterns
queryKeyformat:["feature", id?]— flat arraysselectoption for derived dataenabledflag when dependency not ready
Mutation Patterns
- All API writes through
useMutation— global onError catches 401 - Components call
mutation.mutate()— no try/catch onSuccessfor side effects (navigation, state update)
Zustand Local Stores
- Use Zustand for: coin, streak, notification (local state only)
- Sync with backend on app launch via
loadXxx()functions - No async in store — async in
loadXxx()functions inapi.ts
Auth Flow
- Login → save tokens → update auth state
- App launch → restore from SecureStore → refresh token
- 401 →
tryRefresh()→ if fail → logout → redirect login - Logout → clear SecureStore → clear QueryClient cache
Error Handling
- Never try/catch in components for toast
- Global QueryClient onError handles 401 → logout
- Use React Native
Alert.alert()for user-facing errors - Log errors for debugging, but don't expose raw errors to UI
Data Rules
- Backend response:
{ data: T }→ApiResponse<T> - Null handling:
{value && <Component />}— don't hide null with?? fallback - Types defined in
src/types/api.ts— don't inline.json<{...}>
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 repositoryCheckingapps/mobile-v2/.agents/skills/mobile-data-patterns/SKILL.md
Popularity
- Repository stars
- 3
- Repository forks
- 1
- 7-day trend score
- 0
Stars and forks are for the whole GitHub repository, not this skill alone. 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/nghyane/vstep/mobile-data-patterns)