I want to know if there is a way to access the value of a key to add as the value of another key in the same object.
For example I want:
obj = {key1: 'apple', key2: 'applesauce'};
I tried obj = {key1: 'apple', key2: this.key1 + 'sauce'}
Also tried obj = {key1: 'apple', key2: key1 + 'sauce'}
I want it so that updating key1 automatically updates key2.
Thanks