isPointInStroke

fun isPointInStroke(point: DOMPointReadOnly = definedExternally): Boolean(source)

The isPointInStroke() method of the SVGGeometryElement interface determines whether a given point is within the stroke shape of an element.

MDN Reference