-
Notifications
You must be signed in to change notification settings - Fork 35
Attributes
attributeName
The name of the attribute to get.
Get the value of an attribute for the first element in the set of matched elements.
attributeName
The name of the attribute to set.
value
A value to set for the attribute.
Set one or more attributes for the set of matched elements.
attributes
An object of attribute-value pairs to set.
attributeName
An attribute to remove
Remove an attribute from each element in the set of matched elements.
This method does not accept any arguments.
Get the current value of the first element in the set of matched elements.
Set the value of each element in the set of matched elements.
value
A string of text corresponding to the value of each matched element to set as selected/checked.
propertyName
A CSS property name.
Set one CSS property for the set of matched elements.
properties
An object of property-value pairs to set.
Set CSS properties for the set of matched elements.
className
One or more space-separated classes to be added to the class attribute of each matched element.
Adds the specified class(es) to each element in the set of matched elements.
className
One or more space-separated classes to be removed from the class attribute of each matched element.
Remove a single class, multiple classes, or all classes from each element in the set of matched elements.
className
One or more class names (separated by spaces) to be toggled for each element in the matched set.
className
One or more class names (separated by spaces) to be toggled for each element in the matched set.
state
A Boolean (not just truthy/falsy) value to determine whether the class should be added or removed.
Add or remove one or more classes from each element in the set of matched elements, depending on either the class's presence or the value of the state argument.
className
The class name to search for.
Determine whether any of the matched elements are assigned the given class.