How to pass value from child to parent?

I'm trying to make a connection 1.descendant - 2.parent - 3.descendant.

Two of the offspring are inherited from 1 parent, but the data should be transferred first with one child in the parent and then from parent to offspring, because the descendants are not connected.

The link from parent to descendant I can do there I use @Input():
@Input() isSearch: boolean = false;

the parent get it this give

Question to me from another descendant to pass this value headerSearch parent?

I hope I'm clearly written. As I understand there @Output() - but it is to listen to events, and I at boot just have to pass the boolean value
July 2nd 19 at 17:03
2 answers
July 2nd 19 at 17:05
Can be done through the service. Creates an instance of the service where the value is stored. One descendant associated with services by means of data binding, the second requests via the method.
And could you show a visual example? - dahlia_Bog commented on July 2nd 19 at 17:08
Oh. Writing to the phone. - Shaina commented on July 2nd 19 at 17:11
: I can wait) for Now, just the other tasks solve, and this just does not rest, want to know how it should be correctly - dahlia_Bog commented on July 2nd 19 at 17:14
Found you the answer on the stack - Shaina commented on July 2nd 19 at 17:17
There is a clear diagram - Shaina commented on July 2nd 19 at 17:20
July 2nd 19 at 17:07
yeah, and using @Output()

Find more questions by tags Angular