Xa-el / FootyFriends

2 stars 3 forks source link

Show More #19

Closed AntonCSalvador closed 4 months ago

AntonCSalvador commented 4 months ago

Implement 'Show More' Button in Feed

Description

In order to optimize our Firebase usage and reduce the number of document reads, it's crucial that we implement a "Show More" feature for the feed on the home page (home/+page.svelte). Initially, the feed should load only the first five posts, with an option for users to load additional posts if they choose to.

Scope of Change

Implementation Details

Rationale

Implementing this feature will:

Considerations

Suggested Steps for Implementation

  1. Update the Firebase query in the home/+page.svelte to include pagination logic.
  2. Add a "Show More" button below the initial posts.
  3. Implement the functionality to fetch additional posts when the "Show More" button is clicked.
  4. Adjust the frontend to handle appending new posts to the existing list without reloading the entire component (shouldnt be that bad)

Conclusion

Adding a "Show More" feature will not only optimize our Firebase usage but also enhance user experience by reducing wait times and providing more control over data usage. This is an essential update that aligns with our goals of improving performance and cost-efficiency.

KalebE36 commented 4 months ago

Completed!