/plushcap/analysis/supabase/supabase-react-native-offline-first-watermelon-db

Offline-first React Native Apps with Expo, WatermelonDB, and Supabase

What's this blog post about?

The text discusses using WatermelonDB as an offline-first data store in a React Native/Expo app that syncs with a Supabase backend. Offline-first apps have the advantage of working primarily offline and providing instantaneous reading and updating of data when used online. However, they can also lead to stale data or conflicts if changes are made while offline. The tutorial demonstrates how to set up WatermelonDB, create a local data model, sync with Supabase using RPCs, and handle timestamp conversions between WatermelonDB and Supabase/Postgres. While this approach can enhance user experience in terms of reliability and performance, it also adds friction when changing the data model.

Company
Supabase

Date published
Oct. 8, 2023

Author(s)
Benedikt Müller

Word count
1253

Hacker News points
None found.

Language
English


By Matt Makai. 2021-2024.