-
Notifications
You must be signed in to change notification settings - Fork 20.5k
Description
The third variation of toggleClass method in documentation is as follows:
.toggleClass( [switch ] )
switch
Type: Boolean
A boolean value to determine whether the class should be added or removed.
It says "the" class, while no particular class is specified, and it toggles all the class names present in the matched elements.
it would be great if the documentation reads the same.
As a side note:
Also, at later point, the docs says:
if no arguments are passed to .toggleClass(), all class names on the element the first time .toggleClass() is called will be toggled.
It would be nice if it is added as the first variant of the method, along with a better description other than "all class names on the element the first time .toggleClass() is called will be toggled"? " Something like "all class names that were present on the element when .toggleClass() is called for the first time will be toggled" will be better IMHO.