Well the recommended pattern is to break down code by components. So try to 
make at least as many folders as you have specific pages and put code for 
each individual page into it's individual folder. And when you see some 
code that you're repeating (it's common to all, e.g. some specific widget), 
you move this further out, into a "shared" component or similar. 

But your question is a bit vague - what do you mean you've "separated your 
API from UI"? You mean backend API calls? All paired into a service?

Yes, that too. You can split it up by some logical key (dunno what that 
might be for your app), and again, extract shared code into a common base 
service which everybody inherits from.


Zlatko

On Friday, December 1, 2017 at 6:06:30 PM UTC+1, Tito wrote:
>
> Greetings!
>
> I have separated my api from UI as recommended by many here. But now my 
> issue is that my api index.js has grown pretty big. I would like to break 
> this monolithic index.js into smaller .js files. 
> am i being OCD or is this a good pattern?
>
> Thanks!
>

-- 
You received this message because you are subscribed to the Google Groups 
"Angular and AngularJS discussion" 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 https://groups.google.com/group/angular.
For more options, visit https://groups.google.com/d/optout.

Reply via email to