How can I pass a variable to an AngularJs controller without creating a named property for it? -
How can I pass a variable to an AngularJs controller without creating a named property for it? -
i have seen question after different - don't want have create named properties on service info want pass controller.
i have service provides array of items, , each item in array, array.
i pass main array root controller (or directive) using service, that's fine. after want iterate each item in array , create directive controller each item - how pass item nested controller? needs dynamic, obviously, because don't know number of items in array.
if wrap nested controller in directive, can via directive's scope?
edit:
i need iterate items , pass each 1 nested directive or controller. can (in pseudo code)?
<mydirective> <ng-repeat item in arrayofitems> <mynesteditemdirective> <mycontroller>
angularjs
Comments
Post a Comment