Sharing data between controllers

This is the most frequently asked question, when someone wants to test your Angular knowledge.

  1. Broadcast data to all controllers/entire application.
  2. When you want to just inform the parent controller,  use emit instead of broadcast.
  3. Use services
  4. Use root scope (not recommended)