Angular 2应该使用哪种类型的文件夹结构? [英] Which type of folder structure should be used with Angular 2?
问题描述
我是一位开始学习Angular 2的Angular 1开发人员.根据培训材料,有很多不同类型的文件夹结构方法.我将在下面列出每一个,我很想得到人们的意见,关于我应该使用它以及为什么使用它.另外,如果有未列出的方法,但您认为它会更好,请随时列出.
I am an Angular 1 developer that is starting to learn about Angular 2. There are a lot of different types of folder structure methods depending on the training material. I am going to list each one below and I would love to get people's opinions on which I should use and why. Also, if there is a method that is not listed but you feel that it works better, please feel free to list it as well.
通过查看所有这些,方法#3几乎就是我在做Angular 1应用程序时的方式.
By looking at all of these, method #3 is pretty much how I was doing my Angular 1 apps.
方法1:angular2-quickstart
来源: https://angular.io/guide/quickstart
文件夹结构:
方法2:ng-book2
来源: https://www.ng-book.com/2/(必须付费才能查看文件)
Source: https://www.ng-book.com/2/ (have to pay to see the files)
文件夹结构:
方法3:mgechev/angular2-seed
来源: https://github.com/mgechev/angular2-seed
文件夹结构:
推荐答案
现在有官方指南. mgechev/angular2-seed
也与此对齐.参见#857 .
The official guideline is there now. mgechev/angular2-seed
had alignment with it too. see #857.
https://angular.io/guide/styleguide#overall-structural-guidelines
这篇关于Angular 2应该使用哪种类型的文件夹结构?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!