When a function is dependency-injected in AngularJS, the dependencies can be accessed through the function's parameters. Unused dependencies are confusing, and they potentially bloat the application footprint.

Do not include dependencies that are not used by a dependency-injected function.

The following example shows an AngularJS controller with more dependencies than parameters.

This is problematic, since the depB dependency is unused.

  • AngularJS Developer Guide: Dependency Injection.