Or you could … just build it directly on indexedDB. That's what we did for our offline support at Fastmail, with just a small wrapper function to make the API promise based: https://www.fastmail.com/blog/offline-architecture/

The performance has been pretty decent, even with multi-gigabyte mailboxes.

The offline support has been great. I used to have to keep another mail app synced with my fastmail inbox over IMAP just in case I needed access to an email and had crappy connection. Now I can just have the one email icon on my homescreen.

Saw that Fastmail released offline support recently, nice work!

Do you not have any need for CRDT?

No, CRDTs wouldn’t be useful right for what we currently do. If we ever wanted collaborative text editing for something then we’d use them for sure.

Fair enough, not needing CRDTs makes life a lot easier!

And by the way, we didn't opt for an in-house IndexedDB solution because we have targets in which IndexedDB does not exist (mobile, desktop).

How do you handle offline-first in your mobile apps? Are your mobile apps webviews?