There's currently no way to override the resource name without specifying each individual URL. This PR allows you to set the full path to the resource. Example:
angular.module('app', ['ActiveResource'])
.factory('Post', ['ActiveResource', function(ActiveResource) {
var Post = function (data) {
// ...
};
Post.inherits(ActiveResource.Base);
// this will use "posts" as the resource name
Post.api.set('http://api.faculty.com/posts', true);
return Post;
});
There's currently no way to override the resource name without specifying each individual URL. This PR allows you to set the full path to the resource. Example: