Hey guys, 

After reading about best practices and ng-boilerplate I have decided to 
change my project structure to something more oriented to modules so I have 
now many different ones (I guess I was sold by the idea of having different 
components you can reuse among different projects). Anyway after i made 
this separation of code I am getting now the following exception:


   1. Uncaught TypeError: Cannot read property 'apply' of undefined from 
   mixJsApp.main angular.js:2914
      1. (anonymous function)angular.js:2914
      2. forEach
   


This just happens with the modules that have directives in. Not very sure 
what I m missing here. This is my main module configuration:

angular.module('mixJsApp', [

        'mixJsApp.domain',
        'mixJsApp.services',
        'mixJsApp.administration',
        'mixJsApp.dashboard',
        'mixJsApp.trading',
        'mixJsApp.reports',
        'mixJsApp.research',

//The following 4 are the ones that have directives and are the ones that 
give me the exception. (No matter what order I use) 

        'mixJsApp.main' 
'mixJsApp.currency',
        'mixJsApp.market',
        'mixJsApp.commissions'
        ])
  .config(['$httpProvider', function($httpProvider) {
        $httpProvider.defaults.useXDomain = true;
        delete $httpProvider.defaults.headers.common['X-Requested-With'];
    }]);


Please any help would be appreciated
Luis

On Thursday, February 28, 2013 9:03:56 PM UTC-5, Josh David Miller wrote:
>
> Hello everyone!
>
> When I start a new AngularJS project, I always follow the same few steps: 
> recreate a directory structure, copy an old Grunt file, create basic HTML, 
> add the AngularJS overhead, etc. And all of this is before I even start on 
> my project! So I created something that aims to alleviate that, and I post 
> it here so that both (a) it may be of help to others, and (b) I may solicit 
> feedback on the implementation.
>
> ngBoilerplate contains everything a developer needs to kickstart new 
> AngularJS projects: a best-practice directory structure to support 
> scalability and code reuse, an intelligent build system that saves time, 
> and a couple of common web design libraries like Bootstrap. The idea is 
> that I (or whomever) can simply fork the repository and start developing a 
> new app. I created a similar one when I worked with Dojo and found it quite 
> helpful; I'm attempting to  reclaim that success using AngularJS.
>
> For the record, there are competing kickstarters, seeds, sprouts, and 
> boilerplates, but they don't seem to adhere to some of the philosophical 
> principles of architecture I think are required for a good app, so I 
> created my own. The GitHub page discusses these philosophical points in 
> more detail.
>
> Also, before I forget - thanks to everyone here. Most of this I learned 
> from this mailing list and from working on other open-source projects. For 
> example, the directory structure is similar to the awesome `angular-app`.
>
> Some feedback would be awesome! So if you have a few spare minutes, hop on 
> over to http://bit.ly/ngBoilerplate and tell me what you think - I'd love 
> some feedback!
>
> Josh
>

-- 
You received this message because you are subscribed to the Google Groups 
"AngularJS" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/angular.
For more options, visit https://groups.google.com/d/optout.

Reply via email to