Hey, The idea is fine but this is done via a service or a store or a global state. Both the main page and the directive would be listening to events, data changes in the service... Hope this helps
*Bastien Lemaire* On Tue, 12 May 2020 at 16:09, Garey Mills <garey.mi...@gmail.com> wrote: > I have a directive that models and displays a game board. When a piece is > captured on the board, I want that to be recorded and displayed in another > widget, which will probably have to be a directive) on the same page as the > board directive. I cannot see the way to call a function on the recording > directive. I have read the developer's guide for directives carefully, but > it seems to be very complex for what seems a simple action. How do you, > from a directive, call a function on another directive that increments or > decrements a variable on the called directive? > > > Any help would be appreciated. > > -- > You received this message because you are subscribed to the Google Groups > "Angular and AngularJS discussion" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to angular+unsubscr...@googlegroups.com. > To view this discussion on the web visit > https://groups.google.com/d/msgid/angular/8e25393e-7ea0-407a-be77-201602c18bcb%40googlegroups.com > <https://groups.google.com/d/msgid/angular/8e25393e-7ea0-407a-be77-201602c18bcb%40googlegroups.com?utm_medium=email&utm_source=footer> > . > -- You received this message because you are subscribed to the Google Groups "Angular and AngularJS discussion" group. To unsubscribe from this group and stop receiving emails from it, send an email to angular+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/angular/CAJ7E9zF8q4NC8ZOSEK3vb-JDNAa7u%3DpaW7wDBgupsPo-xyF4_w%40mail.gmail.com.