Hi, 

ng-include is not good for this case. In your example, in the recursive 
template is used "item", but this every refers to the same item. 

I think better solution is using recursive directive with isolated scope. 
I changed your example 
here http://plnkr.co/edit/e4j0KbCq2G9tTZhzCwIx?p=preview

Next improvement should be using controllerAs and maybe rewrite directive 
to components... but it is up to you.



Dne úterý 15. listopadu 2016 23:00:26 UTC+1 Scott Wilson napsal(a):
>
> I have a directive with an item template that recursively references 
> itself but is not properly rendering out children beyond the first level. 
> I've looked at several examples and it seems my example only differs in 
> that my items are loaded by page via AJAX requests. Below I've linked to an 
> example of the problem.
>
> http://plnkr.co/edit/16wf1MS7vbk3qH8tcE7q?p=preview 
> <http://www.google.com/url?q=http%3A%2F%2Fplnkr.co%2Fedit%2F16wf1MS7vbk3qH8tcE7q%3Fp%3Dpreview&sa=D&sntz=1&usg=AFQjCNF8DO_rwqG4lSDoj_yD24VRTM3g4Q>
>

-- 
You received this message because you are subscribed to the Google Groups 
"Angular" 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.

Reply via email to