Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Display entire leaderboard, not just top 100 #68

Merged
merged 2 commits into from
Sep 15, 2023

Conversation

SheepTester
Copy link
Member

I do not think it would be too bad if we loaded the entire leaderboard at once

Info

Closes #61. (If there is no issue for this pull request yet, please create one or
delete this line if the pull request is for a very minor tweak).

Description

What changes did you make? List all distinct problems that this PR addresses. Explain any relevant
motivation or context.

It now requests the entire leaderboard, not just the first 100 users.

Changes

  • Added an optional params parameter for getLeaderboard that mirrors the query parameters supported on the backend
  • I added a doc comment mentioning that the default limit is 100 since it isn't documented anywhere

I'd like to test this change on the production leaderboard data because it has a lot more users and images. My guess is, NextJS only loading images once they come into view should help with load times significantly, so doing pagination or using a virtualized list might only hurt user experience (since you can't use native browser search, copy/print the entire web page, etc)

Type of Change

  • Bug Fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as
    expected)
  • Logistics Change (A change to a README, description, or dev workflow setup like
    linting/formatting)
  • Continuous Integration Change (Related to deployment steps or continuous integration
    workflows)
  • Other: (Fill In)

Testing

I have tested that my changes fully resolve the linked issue ...

  • locally on Desktop.
  • locally on mobile - use https://ngrok.io to get a copy on a mobile device
  • on the live deployment preview on Desktop.
  • on the live deployment preview on Mobile.
  • I have run and passed all new and existing Cypress tests. Add screenshots below.

Checklist

  • I have performed a self-review of my own code.
  • I have followed the style guidelines of this project.
  • I have documented my code's src/lib functions and commented hard to understand areas
    anywhere else.
  • My changes produce no new warnings.

Screenshots

Please include a screenshot of your Cypress testing suite passing successfully.

If you made any visual changes to the website, please include relevant screenshots below.

image

I do not think it would be too bad if we loaded the entire leaderboard at once
@vercel
Copy link

vercel bot commented Aug 22, 2023

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
membership-portal-ui-v2 ✅ Ready (Inspect) Visit Preview 💬 Add feedback Sep 15, 2023 1:32am

@SheepTester SheepTester merged commit d2b6c57 into main Sep 15, 2023
@SheepTester SheepTester deleted the sean/full-leaderboard branch September 15, 2023 01:54
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants