标签:xxx color this his sele targe UNC href apr
d3.select("xxx") .each(function (d) { //this表示当前element 而 d表示绑定的数据 something(this); });
注意each里的this,这个文档里说得明白http://rajapradhan.com/blogs/d3-js-v4-essentials/d3-selections/
The each() method invokes the specified function for each of the selected element.
The ‘this’ inside the function refers to the current element of the selection being iterated.
标签:xxx color this his sele targe UNC href apr
原文地址:https://www.cnblogs.com/xuanmanstein/p/9945962.html