Skip to content

a simple querySelector / querySelectorAll method / shadow dom traverser.

License

Notifications You must be signed in to change notification settings

nathnolt/query-selector-all-shadow-root

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

8 Commits
 
 
 
 
 
 

Repository files navigation

query-selector-all-shadow-root ( $$$ )

a simple querySelectorAll method for shadow dom

Usage

var matchingElements = $$$('.my-selector')

From a different starting node:

var myElement = $$$('#element')[0]
var buttons = $$$('button', myElement)

Note

The way this script works, is that it will traverse all the elements from the rootNode. This is of course slower than some of the alternative options, but this is simpler to use, and fast enough, for if you are using it sparingly. Basically, you will probably use it sparingly, because if you're using it in your own project, you will probably have access to the elements using the application framework itself.

About

a simple querySelector / querySelectorAll method / shadow dom traverser.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published