Resolved value
{{CSSRef}}
The resolved value of a CSS property is the value after applying active stylesheets and resolving any basic computation those values may contain. The {{domxref("Window.getComputedStyle", "getComputedStyle()")}}
method returns a live {{domxref("CSSStyleDeclaration")}}
object containing the resolved values of all CSS properties applied to a specified element.
Historically, getComputedStyle()
returned the computed value of an element or pseudo-element. As CSS evolved, so did the concept of “computed value”, but the values returned by getComputedStyle()
had to remain the same for backward compatibility with deployed scripts. These values are the “resolved values”.
For most properties, the resolved value is the computed value, but for a few legacy properties (including {{cssxref("width")}}
and {{cssxref("height")}}
), it is the used value. See the specification link below for some per-property details.
Specifications
{{Specifications}}
See also
{{domxref("window.getComputedStyle")}}
{{domxref("CSSStyleDeclaration.getPropertyValue")}}
- Values
- CSS syntax
- At-rules
- Specificity
- Inheritance
- Value definition syntax
- Shorthand properties