If you want to extend the property of this object to a new object you should write your code in a class and constructor method. Example:
class MyObj {
constructor(name) {
this.name = name;
}
}
const myObj = new MyObj('I am Jhone');
class AnotherObj extends MyObj {
constructor(name...