Angular going forward
'puzzle pieces' === 'modules'

Reuse existent pieces of code tested and done properly

AJAX Requests: 
$http, ngResource, restangular
all SERVICES?

what is a service?!

Reuse existent pieces of code tested and done properly

Angular Routing

 

ui-router: MODEL vs ngRoute link

introduction video

activating states

Reuse existent pieces of code tested and done properly

Angular + lodash
  functional utilities  

Reuse existent pieces of code tested and done properly

Angular + Factories example

 

//service style, probably the simplest one

myApp.service('helloWorldFromService', function() {

this.sayHello = function() {

return "Hello, World!"

};});

 

//factory style, more involved but more sophisticated

myApp.factory('helloWorldFromFactory', function() {

return {

sayHello: function() {

return "Hello, World!"

}};});

$http service

function $http(requestConfig) {
  var config = {
    method: 'get',
    transformRequest: defaults.transformRequest,
    transformResponse: defaults.transformResponse
  };
  var headers = mergeHeaders(requestConfig);

  extend(config, requestConfig);

...

...

Made with Slides.com