Not sure if what I want is possible, but
This works:
pointer = arr1 = ['a','b','c'];
arr1.splice(0, 1);
console.log(pointer); // ['b','c']
What I would like, but does not work:
pointer = arr1 = ['a','b','c'];
arr1 = ['e','f'];
console.log(pointer); // desired ['e','f']
console.log(pointer); // reality ['a','b','c']
Is there any way around this, other than constantly re-updating the pointer
variable each time arr1
gets reassigned?