I am using Typescript with Angular as described here http://www.youtube.com/watch?v=WdtVn_8K17E
class MyController {
thescope: any;
static $inject = ['$scope'];
constructor($scope) {
$scope.vm = this;
this.thescope = $scope;
}
...
}
I want to create an instance of this controller. What do I have to use as the $scope parameter?
var mc = new MyController(whatParameterHere?); //
nodeselectedevent where I want to call a function of the controller. Maybe I have wrong design?initfunction on the controller and bind it to ng-init. I then create the jQuery component (jstree) in the init function. If the jsTree has an event then you should be able to wire up that event inside the controller and call whatever controller based function you wish. Without code, it is hard to give you a proper solution.