Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVASCRIPT

check if element is visible or hidden in dom

// Where el is the DOM element you'd like to test for visibility
function isHidden(el) {
    var style = window.getComputedStyle(el);
    return (style.display === 'none')
}
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #check #element #visible #hidden #dom
ADD COMMENT
Topic
Name
5+3 =