Scroll element to top of window

Old post, but thought would ask…

I need to be able to scroll to a position which the coordinates are set based on the opening browser viewport. I cannot get the coordinates from editor toolbar because they will not be correct.

Is there a way we can write to the console.log coordinates of an element?

Cheers,

Calum