Classes constructor and object constructor

Hello campers , I am confused about the difference between those constuctors , I know that classes are syntactical sugar but why it is using constructor word fro declaring parameteres what I know is that the constructor is a property existed in function constructor prototype wich shows that is it created by that function .

The constructor function is the function used to initialise the properties of the object. The constructor property is a reference to that function.

function MyClass(foo) { = foo;


class MyClass {
  constructor(foo) { = foo;
> const myNewClass = new MyClass('hello')
> myNewClass.constructor
function MyClass(foo) { = foo }