Ability to pin a subtree of the dom open across page reloads



6 years ago
5 months ago


(Reporter: fitzgen, Unassigned)


Firefox Tracking Flags

(Not tracked)


Imagining a context menu item "pin subtree open" or something that makes it so when I reload the page, the same subtree will automatically be opened again.
I think it should be automatic, like how the debugger remembers the expanded nodes in the variables view.
I like this idea, and it's relatively easy to implement I think.
At inspector-panel level, we already store the unique css selector of the currently selected node : http://mxr.mozilla.org/mozilla-central/source/browser/devtools/inspector/inspector-panel.js#390
We use this so that at the next reload, we can re-select the same node.

It wouldn't be hard to store the list of expanded nodes in the same fashion.

I'm wondering though if the usecase of refreshing the page specifically to clean up the inspector's state is a valid one. It seems like valid to me.
So if we want to remember expanded nodes, then I think we should also implement (via a ctx menu option probably) a way to collapse all nodes at once.

By the way, I like Panos' view on this being automatic.
OS: Mac OS X → All
Priority: -- → P2
Hardware: x86 → All
Inspector bug triage (filter on CLIMBING SHOES).
Severity: normal → enhancement
Priority: P2 → P3


5 months ago
Product: Firefox → DevTools
You need to log in before you can comment on or make changes to this bug.