dollar-inject

Sets the arguments passed into dollarInject() as $inject on the method

Downloads in past

Stats

StarsIssuesVersionUpdatedCreatedSize
dollar-inject
1.0.17 years ago8 years agoMinified + gzip package size for dollar-inject in KB

Readme

dollar-inject
Greenkeeper badge
$inject = require('dollar-inject')

sessionController = $inject 'session', '$http',
  (session, $http) ->
    ...

basically does
function sessionController (session, $http) {}
sessionController.$inject = ['session', '$http']
Why?
Because we're still using coffee-script
And the bracket notation is a bit annoying sometimes:
sessionController = ['session', '$http', (session, $http) ->
    ...
]