For example:
parent directive template:
<ul class = "parent">
<child-directive></child-directive>
</ul>
child template:
<li
class = "child"
[class.active]="isActive(item)"
(mouseenter)="activateItem(item)"
(click)="selectValue(item,$event)">
<a class = "label" >
{{label}}
<a>
<a class = "action1">X</a>
</li>
since i use third party css framework i need to have no additional tags
between [parent], [child] and content of [child]
but i need to listen to events on top level of child directive
if i use your suggestion i will have to do something like this in parent
template
<ul class = "parent">
<li
class = "child"
child-directive
>
</li>
</ul>
and child template will have multiple nodes on top level.
PS. while i was writing this i have found decorator:
@HostListener
i think it will suffice for current task
вторник, 6 сентября 2016 г., 19:50:15 UTC+3 пользователь Sander Elias
написал:
>
> Hi Andrey,
>
> The sample you provided will just run without an issue. Can you provide
> something that explains your problem in a bit more detail please?
>
> Regards
> Sander
>
--
You received this message because you are subscribed to the Google Groups
"AngularJS" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To post to this group, send email to [email protected].
Visit this group at https://groups.google.com/group/angular.
For more options, visit https://groups.google.com/d/optout.