I have an angular controller (generated by typescript):
class FileManagerController {
...
constructor($scope) {
$scope.vm = this;
...
}
...functions...
}
How can I use this controller in the directive?
var myApp = angular.module('myApp', ])
.directive('ngFilemanager', function () {
return {
restrict: 'EA',
require: '^ngModel',
scope: {
ngModel: '='
},
templateUrl: '/templates/filemanager.html',
controller: ???
}
});