You have two ways that you can do this:

explorer.factory("service", function ($http, $q) {
    var myService = {
        functionA:function(){return something;},
        functionB:function(){return someOtherthing;}
    };

    return myService;
});

or you can do this:

explorer.factory("service", function ($http, $q) {
    functionA:function(){return something;}

    functionB:function(){return someOtherthing;}


    return {
         doThis:functionA,
         doThat:functionB
    };
});

Either way works.

-- 
You received this message because you are subscribed to the Google Groups 
"AngularJS" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/angular.
For more options, visit https://groups.google.com/d/optout.

Reply via email to