feat: implement React Query for Supabase data fetching

- Install @tanstack/react-query and async-storage-persister
- Wrap app with QueryClientProvider in root layout
- Migrate useSupabaseData hooks to React Query
- Add loading skeleton components for better UX
- Configure 5-minute stale time and 24-hour cache
- Add query keys for proper cache management
- Remove duplicate files and clean up structure
This commit is contained in:
Millian Lamiaux
2026-03-17 14:25:41 +01:00
parent e13d917466
commit b1741e965c
4 changed files with 345 additions and 383 deletions

View File

@@ -19,6 +19,9 @@
"@react-navigation/elements": "^2.6.3",
"@react-navigation/native": "^7.1.8",
"@supabase/supabase-js": "^2.98.0",
"@tanstack/query-async-storage-persister": "^5.90.24",
"@tanstack/react-query": "^5.90.21",
"@tanstack/react-query-persist-client": "^5.90.24",
"expo": "~54.0.33",
"expo-application": "~7.0.8",
"expo-av": "~16.0.8",