Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVASCRIPT

check if element has specific child javascript

const divElement = document.querySelector('div#rootElement');
document.body.contains(divElement); // return bool
 
PREVIOUS NEXT
Tagged: #check #element #specific #child #javascript
ADD COMMENT
Topic
Name
3+3 =