SyntaxFix
Write A Post
Hire A Developer
Questions
.getBoundingClientRect() returns the size of an element and its position relative to the viewport.We can easily get following
Example :
var element = d3.select('.elementClassName').node(); element.getBoundingClientRect().width;