Frameworks59k+ stars
Angular
The original AngularJS framework that started it all
Commit Details
- Message
- "Initial commit"
- Author
- Misko Hevery
- Date
- 2010-01-06
- Hash
- 0a478a5caba21a9e8d96a7b3d8b45e7d4d5f4a3c
Fun Fact
Misko Hevery bet his manager he could rewrite a 17,000-line project in 2 weeks using Angular. He did it in 3 weeks with 1,500 lines.
</>First Code
JavaScript
/**
* @license AngularJS
* (c) 2010 Google, Inc.
* License: MIT
*/
angular.module = function(name, requires) {
return moduleInstance;
};
function Scope() {
this.$$watchers = [];
}
Scope.prototype.$watch = function(watchFn, listenerFn) {
var watcher = {
watchFn: watchFn,
listenerFn: listenerFn
};
this.$$watchers.push(watcher);
};
Scope.prototype.$digest = function() {
this.$$watchers.forEach(function(watcher) {
watcher.listenerFn();
});
};← All Projects
16 of 48