Say I have this html element
<div id="hello" class="hello option john">Hello</div>
<div id="hello" class="hello john">Hello</div>
. Now I select the element with javascript by it's Id. How would I do an equivalent of if($('hello').hasClass('option')){//do stuff}
(jQuery) except in plain Javascript?