I basically have an object, but this object will only be filled after user input. But the other classes are using this object also. But then after I fill the object with the real object, it doesn't get updated in the other classes.

Example :

```
var x = {
  text: null
}
var y = {
  text: x.text
}

x.text = 'trlalala';

console.log(y.text);
console.log(x.text);

```

but when I run it, y.text will print out null. But the value should be updated already. One of my friend told me it's because y.text copy the structure of x.text instead of the reference. Been stuck for a while. :\

Any input will be appreciated, thanks!