var out = {
name: "OUT",
in: {
name: "IN",
f: function() {
console.log('in.name =', this.name);
console.log('in.parent.name =', this.parent.name);
}
},
init: function() {
this.in.parent = this;
return this;
}
}.init();
out.in.f();