HTML
CSS
JS
1
Writing JS
2
Variables
3
Math and logic
4
Functions
5
Loops
6
The Document Object Model (DOM)
7
Events
JavaScript
JS
1
Writing JS
2
Variables
3
Logic and math
4
Functions
5
Loops
6
The Document Object Model (DOM)
7
Events
1
Writing JS
Coming soon!
Overview
JS syntax
JS comments
Applying JS
<script>
(internal JS)
<script src=""> (external JS)
Testing JS
Browser console
console.log()
alert()
2
Variables
Coming soon!
Defining variables
Overview
const
let
var
let vs. var
Data types
Overview
Strings
Numbers
Booleans
Arrays
Objects
3
Logic and math
Coming soon!
Operators
Overview
Arithmetic
Comparison and logical
Assignment
Conditionals
if () {} else {}
switch
Conditional (?) operator
Rounding numbers
Math.round()
Math.floor()
Math.ceil()
Randomization
Math.random()
Random number between two values
Random integer (rounded number) between two values
Random value from an array
4
Functions
Coming soon!
Creating functions
Overview
Defining functions
Arrow functions
Parameters/arguments
Function scope
Using functions
Running functions
return
Side effects
5
Loops
Coming soon!
Basic loops
while
for
for...in
for...of
break, continue
Repeating and delaying code
setInterval()
clearInterval()
setTimeout()
clearTimeout()
6
The Document Object Model (DOM)
Coming soon!
Overview
Introduction
Element objects
All about objects
Objects
Properties
Methods
Property accessors
Constructing objects
this
Targeting elements
document.querySelector()
document.querySelectorAll()
document.getElementById()
document.getElementsByClassName()
document.getElementsByTagName()
.closest()
Changing content
.innerHTML
.textContent
.innerText
.outerHTML
Changing CSS
.classList
.style["property-name"] = ""
Changing attributes
.setAttribute()
.getAttribute()
.hasAttribute()
.removeAttribute()
Creating and moving elements
document.createElement()
.append()
.prepend()
.remove()
7
Events
Coming soon!
Event handlers
Overview
.addEventListener()
.removeEventListener()
Inline event handlers
Event Objects
Overview
.preventDefault()
Special cases
Draggable elements
Custom cursor
Parallax scrolling
Parallax hover
Observers
Intersection Observer
Resize Observer
Mutation Observer