Marcelo F.
Marcelo F.

Reputation: 395

Is there a way to know how inline css property value was set using developer tools?

i'm having a bad time with a javascript-based layout, so I was wondering if there's a way, using Chrome Dev Tools, to know, for example, which line of JS set my element's width. Is chrome capable of detecting that?

Upvotes: 0

Views: 52

Answers (2)

Alexander Pavlov
Alexander Pavlov

Reputation: 32306

Since an inline CSS property change actually modifies your element's "style" attribute, you can as well break on the element's attribute modifications (in the Elements panel, right-click an element and choose Break on... -> Attribute Modifications).

Upvotes: 1

laurencedorman
laurencedorman

Reputation: 166

Under the Sources tab of the Chrome developer tools you can set the execution to pause on DOM mutation. Here is the link to the relevant section of the documentation

enter image description here

Upvotes: 2

Related Questions