[go: up one dir, main page]

Skip to content

Store a local IDB copy of data for instant recall loads

In reference to this micro-code-review app, it needs a local IDB cache so that future API-provided data is not necessarily a bottleneck for showing data on screen.

Benefits

  • All MRs have immutable versions. If loading a specific version, no API call would be required at all.
  • Loading any MR could optimistically render the most recent version while transparently fetching the latest data from the API.
  • Listening for insert events into the database could simulate a data "stream"
    • Multiple pages of data (e.g. batched files) would transparently update the database without needing to be explicitly managed as pages

Future upgrade paths

  • Having a local database could enable a "quick select" of most recently viewed MRs
Edited by Thomas Randolph