JSFiddle - React, Tailwind, and code Playground
HTML
<svg>
<defs>
<marker id="marker" overflow="visible">
<circle r="10"/>
</marker>
</defs>
<path id="r" d="M20,20h100v100h-100z" marker-start="url(#marker)" marker-mid="url(#marker)"/>
</svg>
JavaScript
function rectToString(rect) {
return rect.left + "," + rect.top + "," + rect.width + "," + rect.height;
};
var p = document.createElement("p");
p.textContent = "bbox: " + rectToString(document.getElementById("r").getBoundingClientRect());
document.body.appendChild(p);