Using hasClass

Clicking the button will use Dom's hasClass method to test if the element has the class baz applied.

foo