How can i call some function in angular from javascript . I have a main controller having function which i want to invoke from javascript code. For example, in my controller file i have code like this
app.controller('mainCtrl',function($scope,$http){
//some code
$scope.someFunction=function(value){
// Need value to be accessed here
}
});
Now my code for calling to function is in view.html file, and at bottom im including controller.js . I have simply called method like this .
someFunction(value);