JavaScript JavaScript Basics Introducing JavaScript Where Does JavaScript Go?

Lorenzo Leva
Lorenzo Leva
12,222 Points

document.write

When adding string to a page with this function what is the meaning and use of this: "<h1>...</h1>" and other ones.

1 Answer

Steven Parker
Steven Parker
149,203 Points

When you write strings to a web page, they can be more than just text. They can include HTML code, and those are "tags" that are used in HTML.

Those in particular define a "heading type 1", and by default the text between them will be displayed by the browser in a much larger font that normal text.