Angular 7: How to send and receive a global event?

I study angular, sorry for the stupid question.

I need to make a service for windows with a single instance of the service or be able to send broadcast events and listen to them in each component.

Using @input and @output is not like There is a different nesting of components.

How to solve this issue?

Angular 7: How to send and receive a global event?