the $observe function

http://docs.angularjs.org/guide/directive#attributes
Merge pull request #780 from basarat/patch-6

the $observe function