I'm new to Django framework and currently working on an ecommerce website. Not sure what would be better, when creating new project and new app in Django, does a single app is enough and fine for whole website functionally(all HTML pages, user login/registration etc) or should I use separate apps in my project?
CodePudding user response:
one app for one purpose.
don't describe your app with 'and'.
like: my_app_name' to manage students and exams.
just create 'students' app to manage students and 'exams' to manage exams
CodePudding user response:
As far I have used Django in my profession about four years, I think Django and python is comprehensive kit for building e-commerce web app.
CodePudding user response:
According to the great book on django 'Two scoops of django' we should create an app for only one purpose. If the work of an app is beyond a topic we should create another one.
So I think you should create separate apps for various tasks of your web-application like:
accounts : app for user model
products : app for product model
orders : app for managing orders
payments : app for the order payments
... and many more.