StylePropertyMapReadOnly
The StylePropertyMapReadOnly interface of the CSS Typed Object Model API provides a read-only representation of a CSS declaration block that is an alternative to CSSStyleDeclaration. Retrieve an instance of this interface using Element.computedStyleMap().
Extended by
Methods
[iterator]()
iterator: StylePropertyMapReadOnlyIterator<[string, Iterable<CSSStyleValue, any, any>]>;
Returns
StylePropertyMapReadOnlyIterator<[string, Iterable<CSSStyleValue, any, any>]>
entries()
entries(): StylePropertyMapReadOnlyIterator<[string, Iterable<CSSStyleValue, any, any>]>;
Returns
StylePropertyMapReadOnlyIterator<[string, Iterable<CSSStyleValue, any, any>]>
forEach()
forEach(callbackfn, thisArg?): void;
Parameters
| Parameter | Type |
|---|---|
callbackfn | (value, key, parent) => void |
thisArg? | any |
Returns
void
get()
get(property): CSSStyleValue | undefined;
The get() method of the StylePropertyMapReadOnly interface returns a CSSStyleValue object for the first value of the specified property.
Parameters
| Parameter | Type |
|---|---|
property | string |
Returns
CSSStyleValue | undefined
getAll()
getAll(property): CSSStyleValue[];
The getAll() method of the StylePropertyMapReadOnly interface returns an array of CSSStyleValue objects containing the values for the provided property.
Parameters
| Parameter | Type |
|---|---|
property | string |
Returns
has()
has(property): boolean;
The has() method of the StylePropertyMapReadOnly interface indicates whether the specified property is in the StylePropertyMapReadOnly object.
Parameters
| Parameter | Type |
|---|---|
property | string |
Returns
boolean
keys()
keys(): StylePropertyMapReadOnlyIterator<string>;
Returns
StylePropertyMapReadOnlyIterator<string>
values()
values(): StylePropertyMapReadOnlyIterator<Iterable<CSSStyleValue, any, any>>;
Returns
StylePropertyMapReadOnlyIterator<Iterable<CSSStyleValue, any, any>>
Properties
size
readonly size: number;
The size read-only property of the StylePropertyMapReadOnly interface returns an unsigned long integer containing the size of the StylePropertyMapReadOnly object.