1

I am using Crosswalk in my ionic app to boost performance on Android devices. The problem I have is that Crosswalk does not seem to be able to read values I set in localStorage. When I removed crosswalk and tried the app again, I was able to read the values.

I 'googled' and found this link: https://github.com/crosswalk-project/cordova-plugin-crosswalk-webview1. It says that one of the drawbacks of Crosswalk is that "Crosswalk WebView stores data (IndexedDB, LocalStorage, etc) separately from System WebView". It suggests that "you'll need to manually migrate local data when switching between the two". How would I be able to migrate the data to Crosswalk so I can access it?

I am using Crosswalk version 12.41.296.5 by the way! Thanks guys!

Akinkunle Allen
  • 1,299
  • 12
  • 19
  • if you are using crosswalk-cordova then you will use cordova methods to access local storage so dont worry you can access local storage – raj Jun 12 '15 at 12:22
  • in my crosswalk-cordova app I use expressions like localStorage.setItem('saveUN', false); all the time with no issues. Plugins installed are Camrea, Device, In App Browser – Jess Patton Jun 12 '15 at 14:55

1 Answers1

2

I solved my own problem after so long. Instead of using window.localStorage, I added the Angular-LocalForage module to my project. Angular-LocalForage is an Angular wrapper for the localForage storage library developed by Mozilla. The data now persists across app reset.

Akinkunle Allen
  • 1,299
  • 12
  • 19
  • i use LocalForage but crosswalk still reset after app close and reopen, do i have any special config ? – QViet Jun 09 '16 at 10:48