Add Store Hydration/Serialization API #3078
Replies: 13 comments
-
Remember handling async storage in saving to indexedDB or some native cordova plugin filesystem etc. |
Beta Was this translation helpful? Give feedback.
-
Just throwing out ideas while we're on the topic ... but it would be awesome if something like https://github.com/btroncone/ngrx-store-localstorage became a first class part of ngrx itself. Serializing out for SSR and indexedDB usage is definitely important too, but I would guess that the majority of people are just saving bits of state to localstorage. Plus, the library above doesn't work with feature modules. |
Beta Was this translation helpful? Give feedback.
-
.... When is this going to be implemented? :-( Wasn't it for 7.0?? (today....) |
Beta Was this translation helpful? Give feedback.
-
@brandonroberts When do you think it is going to work? |
Beta Was this translation helpful? Give feedback.
-
@brandonroberts may I take this? |
Beta Was this translation helpful? Give feedback.
-
@Dutchboy @itayod we're going to put together a design for this first, which we have on our list to look at since version 8 has launched. |
Beta Was this translation helpful? Give feedback.
-
@brandonroberts sounds great! |
Beta Was this translation helpful? Give feedback.
-
I'm using ngrx-store-sync that I hacked together. Seems to work for my use case. Putting it here to maybe give you some ideas how to do it (or not do it :D) |
Beta Was this translation helpful? Give feedback.
-
@itayod maybe update your article and repo to 8, because of breaking changes in meta reducer |
Beta Was this translation helpful? Give feedback.
-
@rickvandermey Thanks for noticing me! but I think most of the users are still on version 7.X. so I guess update it now could lead to some confusion at this point :) |
Beta Was this translation helpful? Give feedback.
-
Any news on this one? |
Beta Was this translation helpful? Give feedback.
-
Is there any more news? What have you done to contribute. |
Beta Was this translation helpful? Give feedback.
-
@classifieds-dev relax man! I was just asking! |
Beta Was this translation helpful? Give feedback.
-
To better support state serialization and hydration I recommend adding built-in APIs into @ngrx/store. We should try and tackle the two biggest use cases:
Ideally, we would separate the process of persistence and serialization into two steps:
This would allow authors of persistence strategies to focus on persistence without having to reimplement key filtering or Immutable restructuring.
Beta Was this translation helpful? Give feedback.
All reactions