AngularJS – Modules and Controllers

AngularJS Modules

Modules are the AngularJS way of packaging similar functional codes under a single name. In simple terms it is like package of Java. AngularJS Modules consist of two main parts.

  • An AngularJS module can define its own Controllers, Services, factories and directives.These can be access through out the module.
  • Second part is it can have its own dependencies, when dependencies are defined then AngularJS will go find the module with particular name and make sure their controllers,services,factories and directives are available to this module.

[Read more…]