I’m building a web application and need some advice on handling multiple API endpoints. My backend has two separate endpoints - one returns user information and another provides processed data calculations.
When my React app loads, I want to display both the user list and the calculated data at the same time. I’m pretty new to React and most tutorials I’ve seen only show examples with single API calls.
Is it okay to make two separate requests to both endpoints when the component mounts? Or should I combine this data somehow on the backend first? What’s considered the right approach for this situation?