JSON - Parsing quick help (object name)
-
11-10-2019 - |
Question
Parsing some JSON and one [edit: +"of the"] names for an object is "media:content".
Say I just want to quickly console.log this by,
c.l(results.entry[0].media:content.property)
how must I format that object name so it doesn't throw me a syntax error?
Solution
Something like this:
results.entry[0]["media:content"].property
Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow