Open darrenvong opened 4 years ago
Thanks for filing this!
As mentioned in the thread, the blocker to this is reading storage synchronously when the bundle loads. Once we can do that, adding this is pretty trivial.
Since you mentioned the introduction of the "new architecture" in React Native would be needed to add this, is there any rough timeline on when that would be ready?
There is not, it's being actively worked on right now.
Hey there, it looks like there has been no activity on this issue recently. Has the issue been fixed, or does it still require the community's attention? This issue may be closed if no further activity occurs. You may also label this issue as a "Discussion" or add it to the "Backlog" and I will leave it open. Thank you for your contributions.
Should we add this to the "Backlog"? It'd be a nice feature to have, especially if once synchronous persistant storage is available, it'd be easy to implement for those who knows how this works :D
We don't really have a backlog, but once sync persistent storage is available we'll add this.
This issue is stale because it has been open 180 days with no activity. Remove stale label or comment or this will be closed in 7 days.
The new architecture is available now, so this should be possible, right?
Hey, we have plans to support this as a part of React DevTools improvements for https://github.com/react-native-community/discussions-and-proposals/pull/641.
I will follow up once we get more clarity on when this will be implemented and shipped.
Description
When I am debugging my React Native app using the React DevTools in Flipper, I like to change the settings/preferences available, in particular the component filter to remove components I don't care about so I can locate the component I'm after more easily.
However, when the app is being reloaded, the values of the filter (amongst other preferences such as theme colours) aren't being persisted like they do when you use the same tool in the browser (say Chrome). This is a minor inconvenience as I'd like to not have to set the filters up again each time the app reloads.
Apparently this is a known problem due to the lack of a synchronous persistent storage API available on React Native from this conversation I started with @mweststrate @bvaughn @rickhanlonii on this Twitter thread, and I've been encouraged to raise this issue officially so it can be properly tracked and see if others are interested in this feature/solving it etc!
React Native version:
Steps To Reproduce
Start the Metro bundler and the iOS/Android simulator following the standard Environment Setup instructions. Then:
Expected Results
The user preference persists between app refreshes.