{"action":"opened","issue":{"url":"https://api.github.com/repos/jackmellis/larder/issues/62","repository_url":"https://api.github.com/repos/jackmellis/larder","labels_url":"https://api.github.com/repos/jackmellis/larder/issues/62/labels{/name}","comments_url":"https://api.github.com/repos/jackmellis/larder/issues/62/comments","events_url":"https://api.github.com/repos/jackmellis/larder/issues/62/events","html_url":"https://github.com/jackmellis/larder/issues/62","id":155728659,"number":62,"title":"Rename injector functions","user":{"login":"jackmellis","id":12736176,"avatar_url":"https://avatars.githubusercontent.com/u/12736176?v=3","gravatar_id":"","url":"https://api.github.com/users/jackmellis","html_url":"https://github.com/jackmellis","followers_url":"https://api.github.com/users/jackmellis/followers","following_url":"https://api.github.com/users/jackmellis/following{/other_user}","gists_url":"https://api.github.com/users/jackmellis/gists{/gist_id}","starred_url":"https://api.github.com/users/jackmellis/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jackmellis/subscriptions","organizations_url":"https://api.github.com/users/jackmellis/orgs","repos_url":"https://api.github.com/users/jackmellis/repos","events_url":"https://api.github.com/users/jackmellis/events{/privacy}","received_events_url":"https://api.github.com/users/jackmellis/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/jackmellis/larder/labels/0%20-%20Backlog","name":"0 - Backlog","color":"CCCCCC"},{"url":"https://api.github.com/repos/jackmellis/larder/labels/enhancement","name":"enhancement","color":"84b6eb"},{"url":"https://api.github.com/repos/jackmellis/larder/labels/Node","name":"Node","color":"5319e7"}],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":0,"created_at":"2016-05-19T12:49:33Z","updated_at":"2016-05-19T12:49:33Z","closed_at":null,"body":"Service/factory don't match up to what Angular does, might be nice to rename these to be more consistent.  \n\nService - is actually a singleton, just returns an object or a function or whatever. This is what angular calls a factory, but without the encasing function. Rename to singleton.  \nFactory - this is what angular calls a factory. A function that uses injected parameters to return an object.  \n?? - A service should be an instantiatable class. I.e the installer returns a \"new\" instance of the function.    \n\nI think a factory would be the base type. A singleton is turned into a factory that returns the provided object. A service is a function wrapped in a factory that returns a new instance (think it might need to use some Object.apply magic to pass in dynamic parameters). A factory would work as it does now."}}