What is the key difference between the property() & index() function?Can anybody tell?
Discussion posts and replies are publicly visible
Both functions do the same thing in the same way, as is (vaguely) noted in the documentation.
However, I strongly recommend as a Best Practice, to use them separately, as follows:
This is most important to me since it makes it dramatically easier to read through code afterwards if you're not having to guess whether this "index()" call is trying to find a property or an array index, which can get pretty messy especially when the functions are nested.
There's also a discussion here regarding some of the possible unexpected behaviour when using index() in certain ways.