Django. One app with many models vs. many apps with single model

后端 未结 5 1815
眼角桃花
眼角桃花 2020-12-08 00:42

I\'m currently developing my own weblog in Django. But I\'ve already stucked right in the beginning. So, here is my tree hierarchy:

/pyroot/nemo         


        
5条回答
  •  星月不相逢
    2020-12-08 00:58

    I found this guy on youtube, that says he's dealt with this exact problem: both having a huge app and lots of little ones he considers to be not good.

    http://youtu.be/URztqq1kiqI?t=22m39s

    From my own experience: you don't want one big app, because people can handle better folder trees that are spread a little, but not too much. Also having one app would make harder to grasp what are the components of your project (for new people)

    On the other hand, the more apps you have (that do depend on one another), the more chances you have to run into circular import problems. So you need a strategy for avoiding these things. Here also, newer members would tend to drive the project into problems.

    All in all, people who've developed on more projects, for longer, should usually be the ones making architectural decisions.

提交回复
热议问题