English | 简体中文 | 繁體中文 | Русский язык | Français | Español | Português | Deutsch | 日本語 | 한국어 | Italiano | بالعربية
JavaScript CSSStyleDeclaration Object
removeProperty()Method to remove the properties of the CSS style declaration object.
object.removeProperty(property)
var declaration = document.styleSheets[0].rules[0].style; var oldValue = declaration.removeProperty('color'); document.getElementById("result").innerHTML = oldValue;Test and see‹/›
All browsers fully support the removeProperty() method:
Method | |||||
removeProperty() | Yes | Yes | Yes | Yes | Yes |
Parameter | Description |
---|---|
property | A string representing the name of the property to be deleted |
Return Value: | A string representing the old value of the deleted property |
---|---|
DOM Version: | CSS Object Model |