5 ms·
The article is well-intentioned but misses the point in a few places. For example, the suggestion to have, in an MVC project, three top-level directories: one
by couchand 11y ago
The article is well-intentioned but misses the point in a few places. For example, the suggestion to have, in an MVC project, three top-level directories: one each for models, views, and controllers. This works fine for small projects, but larger projects can see significant benefit by keeping related code together. As with everything, it's a judgment call. The simple "one folder per type of thing" rule may not be applicable in all situations.
- Can_Not 11y agoYeah, where do you add queues, events, observers, helpers, traits, interfaces, etc.?
- awinter-py 11y agoEach of those should be a separate module uploaded to NPM. That was the versions can vary independently (for max compatibility). This technique is named 'carbo-loading' (because of all the spaghetti).
- bdavisx 11y agoIt's been coined the LIFT Principle - aka "Folders-by-Feature" vs. "Folders-by-type". https://github.com/johnpapa/angular-styleguide/blob/master/a1/README.md#application-structure-lift-principle https://github.com/johnpapa/angular-styleguide/blob/master/a... Unfortunately, since the simple examples use Folders-by-type, and many people are incapable (or unwilling?) to think for themselves - they just continue that way of doing things, even in giant projects. Hell, EmberJS embodies the Folders-by-type into the framework.