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

First reaction doesn't refetch the data #1312

Open
vorant94 opened this issue Feb 6, 2024 · 2 comments
Open

First reaction doesn't refetch the data #1312

vorant94 opened this issue Feb 6, 2024 · 2 comments

Comments

@vorant94
Copy link

vorant94 commented Feb 6, 2024

Hi, there

First of all great project! Thank you for all the work you've done!

I just moved from utterances to giscus because of a lot of built-in features (like react integration, dynamic theme change, reactions to post itself and so on). What I notice is that in case discussion is not yet created and user comments the giscus creates the discussion, adds comment on user behalf and refetches the data about it to show the new comment that was just added.

But in case discussion is not yet created and user reacts, the giscus creates discussion, adds reaction on user behalf, but doesn't refetch the data. User needs to either refresh the page or add comment to see his/her reaction...

i'd like to know if it occurs only in my case or in general and if it is not unique for me I think I can try submit the PR fix

I'm using React component inside my Astro blog:

@priya-jain-dev
Copy link

Great Project 👍
I am facing same issue as above.

@neverbot
Copy link

Hi, first time giscus user here, I just added it to a hexo blog.

After adding the first reaction in a page with no comments, the information is in fact "refetched" several times:

  • a POST is done to https://giscus.app/api/discussions (to get a post ID), after that
  • several GET petitions to https://giscus.app/api/discussions?repo=...
  • at some point between those GETs, a POST to the graphql github api to store the reaction (including the post ID).

Sometimes, one of the GETs would return the new info, most of the times the time for creating the new discussion seems to be greater than all the GET operations, and the information is not refetched again.

Don't know if the time to wait before refetching is configurable, I've been a user for like 10 minutes, and this is the first issue I've found related to that.

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

No branches or pull requests

3 participants