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

fix: unable to update content with async resolveData function #877

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

do4Mother
Copy link

@do4Mother do4Mother commented Feb 4, 2025

this is first time i made contribution in open source project. please let me know if i made some mistake. 😄

so i have an issue regarding #876, when i tried to debugging. contentWithPreview variable didn't update correctly if inserting component with async resolveData function.

Copy link

vercel bot commented Feb 4, 2025

@do4Mother is attempting to deploy a commit to the Measured Team on Vercel.

A member of the Team first needs to authorize it.

Copy link

vercel bot commented Feb 4, 2025

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

Name Status Preview Updated (UTC)
puck-docs ✅ Ready (Inspect) Visit Preview Feb 4, 2025 3:47pm

Copy link
Member

@chrisvxd chrisvxd left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hey @do4Mother! Thank you so much for your contribution (and flattered that it's your first ever).

Unfortunately this function is quite intentionally setup to avoid race conditions caused by Zustand and React rendering out of sync. I think your fix is likely to cause other issues, so I'm going to have to debug #876 myself further.

I'll leave this PR open, and if it's the correct fix, go with your contribution 👍

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.

2 participants