It seems like it should be possible to view the localStorage
/chrome.storage
of Chrome Extensions installed on my browser. I've played around with the Developer Tools a bit, but haven't found a way to do this. Any ideas?
When extensions are installed into Chrome they are extracted into the C:\Users\[login_name]\AppData\Local\Google\Chrome\User Data\Default\Extensions folder. Each extension will be stored in its own folder named after the ID of the extension.
Therefore, if you're accessing localStorage from your contentscript, it will be the storage from that webpage, not the extension page storage. Now, to let your content script to read your extension storage (where you set them from your options page), you need to use extension message passing. chrome.
There is a very helpful extension to work with both localStorage
and chrome.storage
that I recently discovered, that works as a Dev Tools panel.
Storage Area Explorer
I did not write this, but it was suggested by the author on some other SO question.
I will proceed to amalgamate the existing knowledge present in several answers, into a simple and comprehensive one. If you vote up this one, please do the same with the ones from @mwkwok and @chaohuang.
It is true that stuff saved using chrome.storage
does not show up in developer tools, there you can only see stuff saved using regular localStorage API. Do this:
Open your extension's background page by going to chrome://extensions/
("Developer mode" needs to be checked to see background pages)
Go to the Console
tab and type this:
chrome.storage.local.get(function(result){console.log(result)})
This will spit the whole storage as a JSON object into the console.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With