This is my demo using angularjs, for creating a service file, and adding service to a controller.
I have two problems with my demo:
sampleApp.controller('sampleApp', ['$scope', '$state', function($scope, $state){
Same thing for me, comma ',' before function helped me in fixing the issue -- Error: ng:areq Bad Argument