Appendix

Support

Accessing the Local Database

There are two databases in local and on remote and they sync via HTTP(S).
The remote database provides API compatible with CouchDB. You can access your data in the remote database directly with the API as described in the section of Accessing Data in the Cloud.
The Inkdrop client app is built on top of a PouchDB for storing data in local and syncing with the remote database. For many parts of the application, the database is the source of truth. Data is written to the local database first, then synced via the API, and changes to the database trigger Actions, Stores and components to refresh their contents. The illustration below shows this flow of data:

Accessing the PouchDB instance

Inkdrop is built with Electron, an instance of the PouchDB is living inside Main Process. Electron's remote module provides
a simple way to do inter-process communication (IPC) between the renderer process (web page) and the main process. Using this IPC, you can access the PocuDB like this: