What I've understood is that object values are just like primitive values, the difference is that there are properties you can look up given an object value.
Which seems very simple, and avoids adding references, and the mystery of what they reference, and avoids confusion with pass by reference, or having a reference that you pass by value, but that value isn't a reference or the thing being referred to ... so, what is that "reference value" supposed to be?
You're being pedantic and it's honestly really off-putting. I have to agree with Manolo Edge—do you not have anything better to do?
Yes, JavaScript doesn't have "references." But it's the accepted terminology in JavaScript land, just like it is in Java and Python.
The important thing to understand is what references are under the hood (pointers). What you call them, at the end of the day, is not important, as long as everyone's on the same page.
What I've understood is that object values are just like primitive values, the difference is that there are properties you can look up given an object value.
Which seems very simple, and avoids adding references, and the mystery of what they reference, and avoids confusion with pass by reference, or having a reference that you pass by value, but that value isn't a reference or the thing being referred to ... so, what is that "reference value" supposed to be?
Ok if they are the same as othere then why are the array not equal? And by reference I mean the address.
Every distinct array has a unique value.
So [] === [] creates two distinct arrays and compares their values (not their elements or properties).
What is an address in javascript?
You're being pedantic and it's honestly really off-putting. I have to agree with Manolo Edge—do you not have anything better to do?
Yes, JavaScript doesn't have "references." But it's the accepted terminology in JavaScript land, just like it is in Java and Python.
The important thing to understand is what references are under the hood (pointers). What you call them, at the end of the day, is not important, as long as everyone's on the same page.
What do they point at?
What's a memory address in javascript?
return && break && throw new Errror('✋');