Line At A Time
Your First Class

Your First Class

class, constructor, this and methods. 6 quick lessons that build on Intro to JavaScript.

0 / 6 lessons complete
Start Lesson 1 Open the JavaScript sandbox ↗
1
What Is a Class?
Write a blueprint and build an object from it.
2
The constructor
Give each object its own starting values.
3
Two Dogs
Build two objects from one blueprint.
4
Methods That Use this
Let a method use the object's own values.
5
Objects That Remember
Change an object's values; it remembers!
6
A Team of Objects
Combine classes with arrays and loops.