0

I read some articles and documentation about structuring projects folder.

If I am not wrong the recommended structure is like this:

  • shared module
  • core module
  • feature modules

My application is small, about 8 models, and same number of services, and just 4 views (login/register, and next 3 in app after authentication). Does make sense follow this convention about these 3 types modules for small projects like mine?

I thinking about following structure:

  • components
  • views
  • services
  • models
  • interceptors
  • ...

What do you think? Is it fine too or should I follow recommended one? Thanks for answers.

Denis Stephanov
  • 4,563
  • 24
  • 78
  • 174

1 Answers1

2

IMHO you should not waste time thinking about requirements that you don't have yet. If you don't see the project ever growing beyond some point, leave the structure the way it's comfortable for you.

For bigger projects I recommend looking into the nx-project how they structure their apps (all modules are an own lib, so there is only the core module that stands out and bootstraps the rest of the app) and Manfred Steyer's slides on Enterprise Architecture in Angular: https://github.com/manfredsteyer https://speakerdeck.com/manfredsteyer/angular-application-architecture-npm-packages-monorepos-and-microservices-nghamburg-march-2018

Phil
  • 7,065
  • 8
  • 49
  • 91
  • Thanks for asnwer, do you have also git of some small project in angular 2+ which is also good for you please? – Denis Stephanov Apr 29 '18 at 15:47
  • Check out Manfred Steyers github, the first link I posted. He has some "flight-booking" repos to demonstrate enterprise architecture. For bigger enterprise projects, I only know of one open source one; their architecture-choices are for the most part general and applicable in other projects as well; but not all of them, so beware: https://gitlab.com/linagora/petals-cockpit – Phil Apr 29 '18 at 15:51