What is the querySelectorAll method in JavaScript? | Document.querySelectorAll() Explained

Published: 23 March 2018
on channel: dcode
42,296
749

In JavaScript, the 'querySelectorAll' method allows you to retrieve a list of Elements that match the CSS Selector that you specify. Essentially, it is a way of finding Elements in JavaScript. It's quitee flexible and lets you search for tags, classes, IDs, parent/child combinations, attributes and so on.

In this video I show you a clear and simple example of how it works on the 'document' object as well as another Parent Node - to only search within that parent.

For your reference, check this out:
https://developer.mozilla.org/en-US/d...

Follow me on Twitter @dcode!

If this video helped you out and you'd like to see more, make sure to leave a like and subscribe to dcode!


On this page of the site you can watch the video online What is the querySelectorAll method in JavaScript? | Document.querySelectorAll() Explained with a duration of hours minute second in good quality, which was uploaded by the user dcode 23 March 2018, share the link with friends and acquaintances, this video has already been watched 42,296 times on youtube and it was liked by 749 viewers. Enjoy your viewing!