I can do var foobar = foo.bar
to access the bar variable.
How would I do this if I had an arbitrary string that told me what element I needed to access. foo."bar"
doesn't work.
I can do var foobar = foo.bar
to access the bar variable.
How would I do this if I had an arbitrary string that told me what element I needed to access. foo."bar"
doesn't work.