Is it possible to push something to an array returned by a function, but not directly? Instead, I want to push it back into the function itself.
hierar() {
return [{ h: 1 }, { h: 2, hh: [{ u: 2.1 }, { u: 2.2 }] }, { h: 3, hh: [{ u: 4 }, { U: 5 }, { u: 6 }] }, { h: 7 }];
}
this.hierar().add({h: 9, hh: [{h:9.1}, {h:9.2}] });