So I have a system where there is a console with a CMS that loads all the content into the DB. So for example it could store all the info for the different cards, sections, and images that are used in the site.
On the world facing website, i’m wondering what the best way to load the data in is.
Imagine I have content collection in the mongo DB that has all the content info for each section of the page, For instance if there is the info cards on the homepage that info would be stored in
So there are a few ways to do this from what I understand.
1: Subscribe to the content and just call the correct info in a cursor as needed… this is obviously undesirable because it wont scale properly.
2: each section will call to the server and request the data it needs as needed … This seems to be the best method but I wonder about having too many requests to the server( though I guess realistically its only probably 4 or 5 requests more on average)
Just wondering what the most preferred method of doing something like this is. Is this silly do to as opposed to just hard coding all the data?