Page MenuHomePhabricator

[web/lib] move reading and populating data to state gate
ClosedPublic

Authored by kamil on Nov 22 2023, 6:34 AM.
Tags
None
Referenced Files
Unknown Object (File)
Thu, Nov 7, 11:37 PM
Unknown Object (File)
Wed, Nov 6, 8:41 AM
Unknown Object (File)
Wed, Nov 6, 8:41 AM
Unknown Object (File)
Wed, Nov 6, 8:41 AM
Unknown Object (File)
Wed, Nov 6, 8:37 AM
Unknown Object (File)
Oct 26 2024, 12:30 AM
Unknown Object (File)
Sep 29 2024, 2:08 PM
Unknown Object (File)
Sep 28 2024, 9:30 PM
Subscribers

Details

Summary

We need to:

  1. See what's in DB before calling callGetInitialReduxState() - based on this we can add params to fetch/skip some store parts.
  2. Wait with rendering app until data from DB is read - similar thing as on native.
  3. Migrate data if needed - we don't have data in redux-persist like on native, if there is no data in DB we need to get it from keyserver and put into DB.

Depends on D9949

Test Plan

Check if app still loads after refresh, and if persistence (drafts) works.

Diff Detail

Repository
rCOMM Comm
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

kamil held this revision as a draft.
kamil published this revision for review.Nov 22 2023, 6:51 AM
tomek added inline comments.
web/redux/initial-state-gate.js
53–58 ↗(On Diff #33485)

Can we await these in parallel?

This revision is now accepted and ready to land.Nov 23 2023, 2:21 AM
web/redux/initial-state-gate.js
53–58 ↗(On Diff #33485)

No because in D9959 callGetInitialReduxState depends on the result of getClientStore - sorry for not commenting on this earlier