1×
Become a member
to unlock all features

Level Up!

Access all courses & lessons on egghead today and lock-in your price for life.

Autoplay

    Add a Node to Your HTML with document.appendChild

    javascriptJavaScript

    This lesson goes over how to create an HTML element and add it to our document. We do this by creating an element with document.createElement. Once we have the element created, we can use document.appendChild to add our element to our HTML.

    We then go over how to connect our JavaScript to a button's onclick event.