CSSStyleDeclaration removeProperty() Method
Example
Remove the color property:
  var declaration = document.styleSheets[0].cssRules[0].style;
var 
  removedvalue = declaration.removeProperty("color");
alert(removedvalue);
Try it Yourself »
Description
The removeProperty() method removes the specified CSS property from a CSS declaration block.
Browser Support
| Method | |||||
|---|---|---|---|---|---|
| removeProperty() | Yes | 9.0 | Yes | Yes | Yes | 
Syntax
 object.removeProperty(propertyname)
Parameter Values
| Parameter | Description | 
|---|---|
| propertyname | Required. A String representing the name of the property to remove | 
Technical Details
| DOM Version: | CSS Object Model | 
|---|---|
| Return Value: | A String, representing the old value of the removed property | 
❮ CSSStyleDeclaration Object
Copyright 1999-2023 by Refsnes Data. All Rights Reserved.