StylePropertyMap

Experimental: This is an experimental technology
Check the Browser compatibility table carefully before using this in production.

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

Properties

Inherits properties from its parent, StylePropertyMapReadOnly.

Methods

Inherits methods from its parent, 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

Browser compatibility

Desktop Mobile
Chrome Edge Firefox Internet Explorer Opera Safari WebView Android Chrome Android Firefox for Android Opera Android Safari on IOS Samsung Internet
StylePropertyMap
66
79
No
No
53
No
66
66
No
47
No
9.0
append
66
79
No
No
53
No
66
66
No
47
No
9.0
clear
66
79
No
No
53
No
66
66
No
47
No
9.0
delete
66
79
No
No
53
No
66
66
No
47
No
9.0
set
66
79
No
No
53
No
66
66
No
47
No
9.0

© 2005–2021 MDN contributors.
Licensed under the Creative Commons Attribution-ShareAlike License v2.5 or later.
https://developer.mozilla.org/en-US/docs/Web/API/StylePropertyMap