How to access where attribute begins with a number?
Opened this issue · 3 comments
dukedougal commented
consider this:
var x = {}
x.y = {}
x.y['3av'] = 'hello'
How can I access x.y.3av using jmespath? It returns an error no matter what I try.
dshvedchenko commented
please try 'x.y."3av"'
dukedougal commented
The implication of this is that if I'm dynamically constructing my search strings - which I usually am - then I need to quote every level.
Isn't this edge case is better suited to happening inside the library?
dshvedchenko commented
I think you can apply it only to cases where your literal starts from digit.