Heads up! To view this whole video, sign in with your Courses account or enroll in your free 7-day trial. Sign In Enroll
Well done!
You have completed JavaScript and the DOM!
You have completed JavaScript and the DOM!
Preview
Learn two properties that provide ways to read and update content in the DOM, textContent, and innerHTML.
Further Reading and Related Videos
Related Discussions
Have questions about this video? Start a discussion with the community and Treehouse staff.
Sign upRelated Discussions
Have questions about this video? Start a discussion with the community and Treehouse staff.
Sign up
[MUSIC]
0:00
Hi everyone! It's time to start shaking
things up a little more in our daily
0:00
tasks web app, starting with
how to read and change content.
0:05
In this video,
I'll teach you two DOM element properties,
0:08
textContent and innerHTML.
0:13
Each provides a different way to read or
update content in the DOM.
0:15
You're going to learn when it might be
best to use one property over the other.
0:20
First, let's look at
the textContent property,
0:24
which enables you to read or set
the textContent of an element in the DOM.
0:27
You need to sign up for Treehouse in order to download course files.
Sign upYou need to sign up for Treehouse in order to set up Workspace
Sign up