I am using d3 to draw a line from a relative svg position and hence want to access the coordinates of the element itself. I tried something like this (where \"this\" refers
I was trying to select an area of svg with a rectangle and get all the elements from it. For this, element.getBoundingClientRect() worked perfectly for me. It returns current coordinates of svg elements regardless of whether svg is scaled or transformed.