StylePropertyMap

The StylePropertyMap interface of the CSS Typed Object Model API provides a representation of a CSS declaration block that is an alternative to CSSStyleDeclaration.

StylePropertyMapReadOnlyStylePropertyMap

Note: This interface is only available on the window thread; unlike other interfaces in this API it cannot be accessed in Worker or Worklet contexts. Worklets receive a read-only snapshot of an element's style through StylePropertyMapReadOnly.

Instance properties

Also inherits properties from its parent interface, StylePropertyMapReadOnly.

Instance methods

Also inherits methods from its parent interface, StylePropertyMapReadOnly.

StylePropertyMap.append()

Adds a new CSS declaration to the StylePropertyMap with the given property and value.

StylePropertyMap.clear()

Removes all declarations in the StylePropertyMap.

StylePropertyMap.delete()

Removes the CSS declaration with the given property.

StylePropertyMap.set()

Changes the CSS declaration with the given property.

Specifications