Assume blog is my object/array. Is one defined for objects and one for arrays? What is the fundamental difference between them and where do I use which one?
Asked
Active
Viewed 47 times
0
-
2There's a big difference between `blog.title` and `blog[title]`. One gets the `title` property of the object `blog`. The other gets the `undefined` property of the object `title`, unless the `title` variable is defined beforehand. – Heretic Monkey Sep 07 '19 at 13:18
-
@HereticMonkey Can you be more specific? Which one gets the title property and which one gets the undefined property? – Aditya Prakash Sep 07 '19 at 13:20
-
The first gets the `title` property. But read the answers to the duplicate -- they go into much more detail. – Heretic Monkey Sep 07 '19 at 13:20
-
Got it. Thanks a lot! – Aditya Prakash Sep 07 '19 at 13:21