Chapter 16: HTML Text Nodes in JavaScript
A Complete Frontend Developer Textbook for Beginners (2023 Edition)
Published in
12 min readJan 22, 2022
This is the textbook version of Lesson 16 of 100 from the Udemy video course: A Complete Frontend Developer Course for Beginners
← Chapter 15: Responsive Layouts with CSS Grid
Overview
This lesson covers the following HTML tags, CSS properties, and JavaScript commands for the first time:
HTML
None.
CSS
None.
JS
- document.querySelector(“p:first-child”).textContent
- document.querySelector(“main”).firstChild.nextSibling
- document.querySelector(“main”).lastChild.previousSibling
- document.querySelector(“main”).childNodes.length
- document.querySelector(“main”).firstElementChild
- document.querySelector(“main”).firstElementChild.nextElementSibling
- document.querySelector(“main”).lastElementChild
- document.querySelector(“main”).lastElementChild.previousElementSibling
- document.querySelector(“main…