Closed chrismytton closed 13 years ago
You may use quotes around property names to both force them to be interpreted as strings and to include chars like spaces and control chars that are allowable by the json spec:
."object" .objectType
Going to leave this open though, it seems like the js parser could disambiguate given context.
Awesome! Thanks for the quick response.
Also worth noting that it seems that the same error occurs when the reserved name is used as part of the property name, so your example would have to be written as:
."object" ."objectType"
Actually I'm getting invalid json string
when using the above selector? Not sure if that is related to the previous issue though?
This selector also gives the same error:
."name" ."first"
oh, that's no good. I'll add a test or two and check it out...
I am testing JSONSelect against some activity streams json. The activity streams specification defines an
object
property in the json.When I try to match the selector
.object .objectType
I am gettingstring required after .
.It seems that
object
is a reserved word for type selectors. I'm hoping a change to this regular expression will solve the problem, but I'm not sure what?