When I initialize an object I want to set this.sound
to the current value of Dog.sound
.
The code below appears to make this.sound
a reference to Dog.sound
's value. How can I grab the value instead of a reference?
init: function() {
this.sound = Dog.sound;
}