Last active
April 15, 2016 17:53
-
-
Save palcisto/ef8826dad5074a7dbd12 to your computer and use it in GitHub Desktop.
Angular Factory Boilerplate
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(function() { | |
'use strict'; | |
angular | |
.module('', []) | |
.factory('serviceName', serviceName); | |
serviceName.$inject = []; | |
function serviceName() { | |
let factory = { | |
square: square | |
}; | |
function square(n) { | |
return n * n; | |
} | |
return factory; | |
} | |
})(); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
@vjwilson good I'll make these changes.