Keeping data in the app after updating in the play store

Asked

Viewed 45 times

-1

Greetings colleagues, I need a help with a small problem I’m having with an app developed with the expo

When we updated the version of our app in the store we changed the architecture of the project and started using the expo, but users are being dislodged because the login data is not being maintained, someone could show me a way to resolve the situation?

Thanks in advance

  • It was not clear to me if the loss of the "session" happens in the migration only or is a problem of the new architecture. So: the user needs to reload how many times after updating the app?

  • the loss of session happens on migration, because I do not have access to the user token to authenticate it after it updates the app

1 answer

0


If the new version does not have a mechanism to recover the token from the old version (how to store it in the internal memory to read later) and you made the update available to all users, I believe that it will no longer be possible to solve efficiently. If the new release is in beta stage and/or you have how to submit a new update with the old version, I suggest encrypting the session data in the old version, persist them in the internal storage and read them in the new version.

UPDATING

Step by step, summarized:

  1. Store the existing token in the app that will be discontinued: it can be in txt, as explained in this answer;
  2. Read the token in the new app: explained in this answer. If you are using Expo, you will need of this method here.

This should be sufficient for the first run of the app after the update. Now you must persist the token "in the domain" of the new app (the same way you would if there was no old app). My suggestion is to use the library Redux-persist.

  • It is still in internal beta for the tests, sorry for the ignorance but how can I persist this data in internal storage? I tried with the Redux persister but did not keep the data

  • Updated response.

Browser other questions tagged

You are not signed in. Login or sign up in order to post.