Skip to content

Live updates to comment threads #2115

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

Draft
wants to merge 13 commits into
base: master
Choose a base branch
from

Conversation

Soxasora
Copy link
Member

@Soxasora Soxasora commented Apr 18, 2025

Description

Closes #791
Polls every 10 seconds a new query called GetNewComments, returning an array of new comments based on the parent Item and appropriately pushes them to the related Item or Comment Apollo Cache fragment.

Media

Example of a live conversation

Screen.Recording.2025-04-19.at.12.31.53.mov

CommentsHeader with polling status
image

Additional Context

Polling is paused if the user is not on the page via document.hidden and stopped after 30 minutes by tracking the time in which the user has loaded the page.

Checklist

Are your changes backwards compatible? Please answer below:
Yes

On a scale of 1-10 how well and how have you QA'd this change and any features it might affect? Please answer below:
5, iterative testing, tbd

For frontend changes: Tested on mobile, light and dark mode? Please answer below:
Yes

Did you introduce any new environment variables? If so, call them out explicitly here:
n/a

TODOs

Subject to updates

  • Load only the specific comment in that position
  • Pause polling when user is on another tab
  • Pause polling when 30 minutes has passed
  • Revisit Apollo Cache logic
  • Test
  • Cleanup

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Live updates to comment threads
1 participant