JavaScript CSSStyleDeclaration item() Method
JavaScript CSSStyleDeclaration item() Method
The item() method is used to return a CSS property name from a CSS declaration block. It is done by index number. The index starts at 0 and so on.
Syntax:-
Its syntax is:- style.item(index)
Return:-
Its return is:- string containing the name of the property
Further Explanation:-
Parameter | Description |
---|---|
index | Required. A number that represents the index of the CSS property |