Using plain JavaScript (not jQuery), Is there any way to check if an element contains a class?
Currently, I\'m doing this:
className is just a string so you can use the regular indexOf function to see if the list of classes contains another string.
className