eventSignal

G

Uses Angular's Renderer2 service to listen to events from DOM elements.

Like the listen method it can accept an element or a string literal for window, document or body. Additionally, if an ElementRef is passed, the nativeElement property will be passed to the listener. As with most of the functions in this library, either a value, signal, function, or observable can be passed. This makes it handy to use with the viewChild query signal.

Events from a signal's element
Events from body element