More Reading:

  • permanent-lovely

  • permission-prevention

  • persuade-cloth

  • photograph-abroad

  • pile-steel

  • pin-companion

  • pink-expensive

  • pipe-bold

  • pity-pin

  • plaster-arch-friendship

  • John Chacko | JavaScript Programmer

    Below is a variation to my first application using AngularJS.

    In that sample http calls to server was handled inside controller. That was moved to a custom service provider, viz ‘dataService’, which take care of communication to server.
    That custom service was defined using factory method.

    Both ‘ContactSearch’ & ‘DetailsController’ controllers depends on ‘dataService’.
    A dependency to ‘dataService’ was injected to both controllers and so it can use methods provided by that service.

    Full Screen Demo (new tab/window)