Clearly the solution to this is to keep a query log in an extra table and periodically stream that to the server as a form of logical replication (plus perhaps being able to load the initial database state from the server side as well, maybe even on-demand using the GH pages trickery until a write forces materialisation into IndexedDB).
As a bonus point this effectively adds yet another level of "Yo, Dawg" which I can't not love just as a matter of principle.