10 ms·
How to do OO in AngularJS
- huula 12y agoOO is important in almost all cases. Because for a cohesive system, you will always have some part to share across components.
- keda 12y agoDoes this code even work? The $s in BaseController seem to come from no where, I believe Angular will inject $scope as first parameter to the constructor, however, in the sample code, it seems to indicate that its pattern. For a good angular+coffeescript scaffold code with basic OO, I recommend take a look at https://github.com/CaryLandholt/AngularFun https://github.com/CaryLandholt/AngularFun