how to know if a div has a class within it code example Example: js check for class in classList element.classList.contains(className);