@angular/core/globals

getOwningComponent

function

Retrieves the component instance whose view contains the DOM element.

  
    function getOwningComponent<T>(  elementOrDir: {} | Element): T | null;
  
  
Jump to details