[HACKTOBERFEST-25] feat: remove the dummy data in the subtext of each tile and implement actual metric change mechanism
hey @amaydixit11, would love to work on this. Can you assign it please ?
@Rudra775 You can start working on the issue. Make sure to rasie PRs only after 1st October.
@HarK-github sure, will do ;)
hello @sumagnadas & other maintainers, I've started working the issue and setup the project locally. Started reading the codebase to become familiar. I had a question, that the update on rating(which is co-related to the previous months data) which is to be done on the HomePage.jsx, does it have to stored in DB like User Details ? or the frontend has to merely make an API call every time we call the page ?
Also if there's any extra info that you'd like to share.. so that we can be on the same page it could be helpful too.
@Rudra775 it has to be persistent somewhere because i dont think the websites provide that information in API. If it does, then we can just call an API and calculate in the frontend. Otherwise, the logic has to be implemented to store it in a database.
Also, currently we don't have an implementation for the overall rank calculation so it would be good to hear some ideas, albeit directly not related to the current issue.
hello @sumagnadas have been working on this issue lately and heres my approach. Creating an endpoint /api/stats/:username/ for fetching from db. whenever users link their platform handles, we’ll fetch their current stats and store them in the database. this will ensure dynamic changes. future updates might be handled via cron jobs, will have to learn about it. please lmk if all this is gtg.
once im done with this then maybe i can workk on overall rank calculation too ?
Sorry for the late response.
That is a good approach. The only thing you have to add to this is platform-wise stats because one user can have the same username in different platforms. It could also be such that the username, as a key, lists the different platforms it is associated with, although I don't think that's a good database model. Anyways, if you can come up with a better approach, apart from the ones, you can go with it too. Apart from that, the approach is good and we can update the database every month or so, depending on our needs.