Skip to content

Instantly share code, notes, and snippets.

View brucecoddington's full-sized avatar

Bruce Coddington brucecoddington

  • Flyover Technical
  • Nebraska
  • 11:42 (UTC -06:00)
View GitHub Profile
@brucecoddington
brucecoddington / resources.js
Last active June 27, 2020 14:42
Wrapping $resource with api and data services.
angular.module('app.resources', ['ngResource'])
.factory('api', function ($resource) {
var api = {
defaultConfig : {id: '@id'},
extraMethods: {
'update' : {
method: 'PUT'
}