."> ."> .">
Old JavaScript examples may use a type attribute: <script type="text/javascript">.
The type attribute is not required. JavaScript is the default scripting language in HTML.
JavaScript can "display" data in different ways:
innerHTML
.document.write()
.window.alert()
.console.log()
.You can skip the window
keyword.
In JavaScript, the window object is the global scope object, that
means that variables, properties, and methods by default belong to the
window object.
This also means that specifying the window
keyword is optional: