I'm trying to detect if an extension is installed by checking if it adds a specific div inside the body.
When the extension is installed it adds the following div in the end of the body:
<div>
  #shadow-root (closed)
    <div id="extension_name">
      <!--div content here-->
    </div>
</div>
Is there a way to detect this element with a simple document query like:
document.body.queryselector(':shadow-root #extension-name')
If not, any suggestion about an efficient way to check if this element exists?
 
    