native-data-fetching

Implement fetch-based network requests with caching and authentication for Expo and React apps.

1|Updated Jun 27, 2026
One-click install
npx skills add https://github.com/babually/bongo-template --skill native-data-fetching-babually
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: native-data-fetching
Source: https://github.com/babually/bongo-template/tree/main/.agents/skills/native-data-fetching
Command: npx skills add https://github.com/babually/bongo-template --skill native-data-fetching-babually

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve?

This Skill helps you implement and debug network requests, API calls, and client-side data fetching without fragile patterns or inconsistent error handling. It reduces common issues like failed requests, poor caching, token handling mistakes, and unclear loading states.

Core Features & Use Cases

  • API Requests: Build fetch-based requests for web or native apps with proper status checking and JSON handling.
  • Caching and State Management: Set up React Query or SWR for stale data control, invalidation, retries, and offline-aware behavior.
  • Authentication and Environment Config: Manage tokens securely, refresh access, and configure environment-specific API URLs.
  • Expo Router Loaders: Use route-level loaders for web data fetching, SSR, static generation, and typed loader data access.

Quick Start

Use the native-data-fetching skill to design the best data-fetching approach for this Expo or React app and include error handling, caching, and environment variable guidance.

Frequently Asked Questions about native-data-fetching

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
What's the best way to handle API calls and data fetching in Expo Router?

To implement data fetching in Expo Router, use route-level loaders for web data fetching, SSR, static generation, and typed loader data access. This approach ensures robust network requests with proper status checking and typed error management.

How do I set up React Query caching and offline support for React Native?

Set up React Query caching by configuring stale data control, invalidation, retries, and offline-aware behavior. This manages state to reduce failed requests and ensure consistent client-side data fetching in React Native.

How do I manage authentication tokens and environment configuration for fetch requests?

Manage authentication tokens by securely handling access tokens, refreshing access, and configuring environment-specific API URLs. This prevents token handling mistakes and ensures fetch-based requests route to the correct environment endpoints.

Does this data fetching approach work for both web and native React applications?

Yes, this approach works for both web and native React applications. It builds fetch-based requests with proper status checking and JSON handling, applying to API calls, caching, and Expo Router loaders across platforms.

Why are my network requests failing with poor caching and unclear loading states?

Network requests fail due to fragile patterns, poor caching, and inconsistent error handling. Implementing robust request flows with proper status checking, typed error management, and stale data control resolves these loading state issues.