I have a directive that is used to render a single user's details.
<user-directive></user-directive/>
I have another directive that nests a repeated collection on the user-directive.
<!-- has some other stuff then the user collection -->
<user-directive ng-repeat="user in vm.users" user="user"></user-directive>
I've tried setting the scope in the single user directive but I can't seem to get the template to populate with the user data from the repeater.
User directive object:
return {
// template etc
scope : { user: '=' }
}
User directive template:
<h1>{{user.name}}</h1>
Any ideas?
Refer fiddle here for reproducing the effect.
user in vm.users(maybe todescribedUseror something like that), as it seems to collide with theuserfrom the directiveuserthatng-repeatcreatesusercould be taking precedence, which would make the properties different, and could be excludingname.