JavaScript Static Methods


Class methods that don't change often are set on the class directly.

You can't use astatic method on an instance; it can only be used on the class of the object.

If you wish to utilize the myCar object within the static method, you can pass it as a parameter: