AngularJS

Angular: Anti-Compressing CoffeScript

You’d get the Unknown Provider error if you’re publishing compressed CoffeeScript. It usually goes like this:

Error: [$injector:unpr] Unknown provider...

So for dependency injection, use arrays, lest they’re lost in compression. Format:

angular.module('library').controller 'AppCtrl', new Array '$scope', '$meteor', '$timeout',
  ($scope, $meteor, $timeout) ->

    # Controller Contents...
Standard