Welcome to the Treehouse Community

Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.

Start your free trial

JavaScript

Tadjiev Codes
Tadjiev Codes
9,626 Points

Hi, wanted to ask a theory question without any code about Classes and inheritance in ES6?

Historically, developers used constructor functions to mimic an object-oriented design pattern in JavaScript Classes in JavaScript (introduced with ES6) do not actually offer additional functionality, and are often described as providing "syntactical sugar" over prototypes and inheritance in that they offer a cleaner and more elegant syntax Because other programming languages use classes, the class syntax in JavaScript makes it more straightforward for developers to move between languages So that means that when we use classes we don't really need prototypes and inheritance that we used to type with the old JAvaScript? As Classes already have that inheritance? Thanks