$state.go() losing previous data


#1

Hi all,

I have this case:

I have form in page A. After fill it up, then go to page B.
tap Back button will back to page A, but all fields in the form are empty.

Is there any ionic view navigation system that allow pages keep in memory?
Thanks :slight_smile:


#2

Store it in $rootScope.


#3

You need to use services for this. Look in the AngularJS services, factories, and providers - they are all (almost) the same thing.