toggleAttribute
The toggleAttribute() method of the Element interface toggles a Boolean attribute on the given element, removing it if present and adding it if not present.
The toggleAttribute() method of the Element interface toggles a Boolean attribute on the given element, removing it if present and adding it if not present.