about summary refs log tree commit diff
path: root/src/state/models/root-store.ts
diff options
context:
space:
mode:
authorEric Bailey <git@esb.lol>2023-11-07 16:06:17 -0600
committerGitHub <noreply@github.com>2023-11-07 14:06:17 -0800
commit96d8faf4b052060b8774ac38c3400ab7d75451ad (patch)
tree9e3483160c623cc5a40d0a34d3d6e2b61ce38c8a /src/state/models/root-store.ts
parentbfe196bac5e618bfbeab4f6fabef3e5a18194868 (diff)
downloadvoidsky-96d8faf4b052060b8774ac38c3400ab7d75451ad.tar.zst
Add persistent state provider (#1830)
* Add persistent state provider

* Catch write error

* Handle read errors, update error msgs

* Fix lint

* Don't provide initial state to loader

* Remove colorMode from shell state

* Idea: hook into persisted context from other files

* Migrate settings to new hook

* Rework persisted state to split individual contexts

* Tweak persisted schema and validation

---------

Co-authored-by: Paul Frazee <pfrazee@gmail.com>
Diffstat (limited to 'src/state/models/root-store.ts')
-rw-r--r--src/state/models/root-store.ts4
1 files changed, 0 insertions, 4 deletions
diff --git a/src/state/models/root-store.ts b/src/state/models/root-store.ts
index cf7307ca3..1943f6dbc 100644
--- a/src/state/models/root-store.ts
+++ b/src/state/models/root-store.ts
@@ -74,7 +74,6 @@ export class RootStoreModel {
       session: this.session.serialize(),
       me: this.me.serialize(),
       onboarding: this.onboarding.serialize(),
-      shell: this.shell.serialize(),
       preferences: this.preferences.serialize(),
       invitedUsers: this.invitedUsers.serialize(),
       mutedThreads: this.mutedThreads.serialize(),
@@ -99,9 +98,6 @@ export class RootStoreModel {
       if (hasProp(v, 'session')) {
         this.session.hydrate(v.session)
       }
-      if (hasProp(v, 'shell')) {
-        this.shell.hydrate(v.shell)
-      }
       if (hasProp(v, 'preferences')) {
         this.preferences.hydrate(v.preferences)
       }