I have copied the xpath Chrome returns for a certain node
//*[@id="__w2_cEfEsuQ_list_item"]/div/div[2]/div/div[1]/div[2]/a[1]
Executing this in the console of Chrome returns
[a]
0: a
length: 1
__proto__: Array(0)
0 can be expanded and contains a lot of subnodes (I removed most of them because SO complained about too much code in my question), like this:
accessKey: ""
tagName: "A"
target: ""
text: "38 Answers"
textContent: "38 Answers"
title: ""
translate: true
type: ""
username: ""
I want an xpath that returns the textContent
and text
nodes. I have tried different variations on //*[@id="__w2_cEfEsuQ_list_item"]/div/div[2]/div/div[1]/div[2]/a[1]/text()
but none has worked. How do I do?