FocusEvent relatedTarget Property
FocusEvent relatedTarget Property
The relatedTarget property is a read-only property and it returns an element related to the element that triggered the focus or blur event. In onfocus and onfocusin events, the related element is an element that LOST focus and in the case of onblur and onfocusout events, related element is element that GOT focus.
Syntax:-
Its syntax is:- event.relatedTarget
Return:-
Its return is:- reference to related element, or null