I received a JSON response that has the following structure:
[
{
"@level": "info",
"@message": "Text"
},
{
"@level": "error",
"@message": "Text"
},
{
"@level": "info",
"@message": "Text"
}
]
I am trying to figure out how to filter this JSON response so that it only displays Objects where
"@level" === "error"
. I know how to typically filter JSON arrays in JavaScript (for example, as explained here). However, in this case, the solution does not seem to work due to the special character @
in the key.
Can anyone help me understand what I might be overlooking here?