So, how to quick start with angular? For example, you need some kind of shopping cart. Here is step by step tutorial: 1. Create app/app.js file - this is our main module. var shoppingCart = angular.module('shoppingCart',['ngRoute']); 2. Then you can configure your routes: shoppingCart.config(['$routeProvider', function($routeProvider){ $routeProvider.when('/',{ templateUrl: 'app/views/home.html', //path to our view controller: 'productController' //page controller }); $routeProvider.otherwise({ redirectTo: '/' }); }]); 3. Create service (app/services/productService.js) which will deliver data into your app. shoppingCart.factory('productService',function($http){ return { getAll: function(){ return $http({"method": "GET", "url": "app/data/data.json"}); /*also you can path here more parameters...
After watching few Richard' Hickey talks I decided to take a look at functional programming. After some researching in internet I choosen to learn Haskell. First time when I seen Haskell code I was scared like most peoples. But then... Haskell is simply awesome. If you are newbie I'd suggest you read this book - this will be useful for any developer. After read it I decided to write small web crawler to summarize what I learn and write post about it. Pls note this post is just my notes to summarize my knowledges, I am do not trying explain clearly FP or haskell monads. If you don't know Haskell suggest you read book first :) My parser has few modules: work with network, parsing, work with DB(Postgre SQL). Here is notes how I did it module by module Network access At the beginning I created very small module which can download html by url. We'll need use HTTP module. Then we can create easy function function which will download html: getHTML:: St...