5 hands-on exercises and 5 find-the-bug challenges for the JavaScript DOM lesson. Every one is checked automatically in the browser — write the code, run it, and the tests tell you what still fails.
Read the heading text and report it in #out.
Change the paragraph text to Updated, then report what it now says.
Report how many child elements the box holds.
Report found when the element is there and missing when it is not.
Report the tag name of the body element.
getElementById takes a bare id, without the hash.
The heading is being read instead of the note.
Ready to write the code?
The editor, the automatic checks and the worked solutions open up with an account.
Open the workspaceThe new text is worked out but never put on the element.
childNodes includes text nodes, so the count is wrong.
A missing element gives null, so it must be checked before use.