Creating Nodes in the DOM

In the JavaScript for WordPress Course, Part 1 on Learning JavaScript Deeply, we explore the DOM in depth, looking at the relationship between Nodes and DOM. Check out our Introduction to the DOM video if you are new to the DOM.

Once we cover how to work with Nodes, we show how we can create our own Text and Element Nodes and append them to each other to build more complex Node clusters. Watch the videos below to learn how to do this with JavaScript and the DOM.

 

Adding Nodes to the DOM

Now that we have looked at how to create nodes and append them to each other we can move on to looking at how to add our created elements into the DOM using the same techniques used for appending nodes to each other.

This is the point in working with the DOM where we can finally start adding our own content and building webpages dynamically.

Taking it Further with Learning JavaScript

Once you know how to work with creating and adding DOM nodes, it’s a good idea to move on to Working with Events.

If this content was a little advanced for you, you may also want to go back and look at our Introduction to the DOM video

To take your learning even further, reserve a seat for the JavaScript for WordPress Master Course. We cover everything you need to know about the DOM and much much more!!!