Closed Joecey closed 4 months ago
@Joecey I just looked into this. Below is a screenshot of currently what goes through the network from opening the endless page to answering the first question:
The first request to "/endless" is to get the first 10 questions. The next request to "/endless" is to update the database with the user's answered option. The last request to "/endless" is for getting the answer counts.
If you want, I can go ahead and make it so that the answer counts are fetched with all of the question data so that all processing of the user's answer choice (except for updating the database) can be done locally.
it would probably be the best if it minimises the amount of requests. If you could draft up a PR for this, that would be great!
For this, should I also minimise the amount of requests in Exam mode? I minimised it in Endless but I believe I will need to do the same in Exam mode.
Oh wow it is the same! Yes if you could limit the requests in exam mode too that would be great!
Describe the bug
I noticed when doing MCQ Endless, there is a fetch request being done every time you submit an answer. It looks like it's refetching all the questions again if I am not mistaken. would it be possible to minimise the amount of calls that occur?
Just as a note, in the case that it is needed so that the answer a user provides is included in the % distribution, I don't think it's critical to do this