How to access the parentNode of a d3.js selection?

前端 未结 4 1256
情歌与酒
情歌与酒 2020-12-05 06:46

I\'ve created the following document:


    ​
    <         


        
4条回答
  •  广开言路
    2020-12-05 07:19

    For some reason, I had to go up 2x levels: console.log(">>"+my_chart.node().parentNode.parentNode.id+"<<")

提交回复
热议问题