paint-brush
Once Upon a Time in Javascript: Classes and Inheritanceby@the_rock
626 reads
626 reads

Once Upon a Time in Javascript: Classes and Inheritance

by Sasha3mDecember 31st, 2019
Read on Terminal Reader
Read this story w/o Javascript
tldt arrow

Too Long; Didn't Read

Classes were introduced as part of ECMAScript 6 standard back in 2015. They are just a "syntactical sugar over javascript's existing prototype-based inheritance" Classes are not natural to javascript, they are still a function. They feel like something natural, but how was it done in javascript before ES6? In this article, we examined how inheritance is done using ES6 standard and how it was done once upon a time in javascript. In fact, class is a function: a function serves as a constructor and returns an object.

Company Mentioned

Mention Thumbnail
featured image - Once Upon a Time in Javascript: Classes and Inheritance
Sasha HackerNoon profile picture
Sasha

Sasha

@the_rock

Software Developer from monday to friday (Healthcare sector), Game Developer in free time

About @the_rock
LEARN MORE ABOUT @THE_ROCK'S
EXPERTISE AND PLACE ON THE INTERNET.
L O A D I N G
. . . comments & more!

About Author

Sasha HackerNoon profile picture
Sasha@the_rock
Software Developer from monday to friday (Healthcare sector), Game Developer in free time

TOPICS

THIS ARTICLE WAS FEATURED IN...

Permanent on Arweave
Read on Terminal Reader
Read this story in a terminal
 Terminal
Read this story w/o Javascript
Read this story w/o Javascript
 Lite