Coder Social home page Coder Social logo

Comments (6)

jasta avatar jasta commented on April 27, 2024

Indeed, I think this can go nicely in the Local Storage section of the Resources tab. I tried to make this work a month back and it wasn't straight forward due to the relationship between HTTP "origins" and that UI. In particular, I'd need to pretend that shared prefs files are security origins at the start of inspection which would add a blocking filesystem traversal step and could slow down initial inspect.

I need to just try it and see how bad it is in practice. If it's slow, we can try something more complex by asynchronously updating the page security origins after we scan for shared prefs files.

from stetho.

bryanstern avatar bryanstern commented on April 27, 2024

How about having Stetho implement a SharedPreferences#OnSharedPreferenceChangeListener instead of inspecting the file directly? This would be handy if you implement your own SharedPreferences and do things like encryption or compression.

from stetho.

jasta avatar jasta commented on April 27, 2024

SharedPreferences are actually sharded on Android. In other words, there can be more than 1 of them and a correct implementation visualizing them should show all that exist. There is a "standard" one which is presumed by the PreferenceManager but it would be incomplete to treat that as the only one.

That said, the real complexity is in figuring out exactly how security origins relate to the "Local Storage" tab. I tried a few random thoughts a while back and couldn't get anything meaningful to show up there. I can try harder, tho :)

from stetho.

jasta avatar jasta commented on April 27, 2024

:)

from stetho.

lynfogeek avatar lynfogeek commented on April 27, 2024

Nice! It was fast!
Can't wait to test :)

from stetho.

jasta avatar jasta commented on April 27, 2024

@lynfogeek 1.0.1 just released with this feature. Looking forward to feedback!

from stetho.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.