Reputation: 2827
See the "..." before "layout-1c"? Firefox seems to have some rules defined for when it should collapse a lengthy element attribute. I want to disable this. Just show me everything, always. How?
EDIT double-clicking the attribute is not good enough. It loses wrapping and makes you manually scroll through a ton. Firebug does everything right from the get-go and I'd like the same behavior for the built-in inspector.
Upvotes: 6
Views: 3048
Reputation: 333
In the official mozilla docs it explains how we can tweak whether to truncate or not, and also how many characters will be shown before being truncated:
Truncate DOM attributes
By default, the Inspector truncates DOM attributes that are more than 120 characters long. Uncheck this box to prevent this behavior. This setting works by toggling the about:config preference "devtools.markup.collapseAttributes". To change the threshold at which attributes are truncated, you can edit the about:config preference "devtools.markup.collapseAttributeLength".
There is a convenient checkbox in developer tools. To find it click the three dots in the upper-right corner and go to Settings:
Upvotes: 5
Reputation: 2827
The most optimal workaround speed-wise seems to be right-click "Edit as HTML".
Fortunately we have a bug filed now https://bugzilla.mozilla.org/show_bug.cgi?id=1198073
Upvotes: 0
Reputation: 749
Truncating long attribute strings is, so far, a feature of the Firefox inspector, as in some cases, attributes may be really long and make it hard to use the tool. Think of base-64 image data-URLs for example.
I understand that this feature might not always be wanted, but for this to change, the inspector's code needs to be changed, there isn't a setting you can use. 2 options:
But to answer the original question, no you can't disable this (other than by changing the code, or writing an addon that would monkey-patch this).
Upvotes: 2
Reputation: 1213
You can double-click the attribute value to show the collapsed content. Note that this is a non-persistent solution.
Upvotes: 1