This is my first message. I’m using Django for a few times, and I really enjoy it (it’s really awesome and easy to develop projects). I just have one question, regarding splitting the project in different apps.
I have a project X, and several features (like a blog, pictures, some datas collected via an API, etc). For me, it’s obvious to split them into several apps (a blog app, a data app, a gallery app, etc…).
My question is: how make a homepage, with different apps? On this homepage, I want to show several informations, from different apps, like the last 3 blog posts, the last 3 pictures, etc, on the same template.
So :
is it possible to do such a thing correctly et properly? And how to?
or should I put those features in a same and single app? It’s more easier to me, but is it the proper way?
One option you have is to create your template with the different areas on the page for data from each app, then have your home page call functions from each app to return the data to be displayed. You can then pass that data into your template to be rendered.
In very rough terms then, your home page view could look something like this: