i'm using angularjs 1.5.7:
i have controller 'mainctrl' gets array of object factory. in html want call child controller trough expression in ng-repeat, if possible parameters. tried this, doesn't work:
<div ng-controller="mainctrl"> <div ng-repeat="module in modules"> <div ng-include="'modules/' + module.type + '.html'" ng-controller="{{ module.type + 'ctrl(' + module.data + ')' }}"> </div> </div>
how can accomplish this?
Comments
Post a Comment