I have json
[
{
"name": "Name1",
"address": "City1\nCountry1"
},
{
"name": "Name2",
"address": "City2 Country2"
}
]
And I am using jayway library to extract "name" using "address". I want to parameterize the "address" using jpath
$.*[?(@.address=='{address}')].name
However, as you can see in json, first address has "\n" on it. Is there a way like normalize spacing for it so whenever I use jpath
$.*[?(@.address=='City1 Country1')].name
the value will still be extracted