how can I browse localStorage on the device

2019-07-13 11:09发布

问题:

I am building an application for android device using the Ionic framework. I want to store my data using localStorage. Now, I understand what it is but I can't find it anywhere on the device. I want to browse it to check if everything is saved as I want to.

I found many different tools to browse localStorage when I create app and run it under my device (real phone not emulator) is there a way to browse data store in localStorage ?

回答1:

Using remote debugging (for Chrome to Android or Safari to iOS) you can easily browser LocalStorage on the device (or emulator). This article documents how to do it with Chrome (https://developer.chrome.com/devtools/docs/remote-debugging) and this one covers Safari (http://moduscreate.com/enable-remote-web-inspector-in-ios-6/).