Skip to content

Use isSuccess when loading#139

Open
mikerowehl wants to merge 1 commit intoscaffold-eth:mainfrom
mikerowehl:recipe-read-issuccess
Open

Use isSuccess when loading#139
mikerowehl wants to merge 1 commit intoscaffold-eth:mainfrom
mikerowehl:recipe-read-issuccess

Conversation

@mikerowehl
Copy link

Using isLoading for Wagmi state can show the value before the hook starts the network request. The other recipes look to already account for that and they use isPending. isSuccess is great for this simple read case, as it only goes to true if the value has been loaded successfully.

@vercel
Copy link

vercel bot commented Dec 5, 2025

@mikerowehl is attempting to deploy a commit to the BuidlGuidl Team on Vercel.

A member of the Team first needs to authorize it.

Using isLoading for Wagmi state can show the value before the hook
starts the network request. The other recipes look to already account
for that and they use isPending. isSuccess is great for this simple read
case, as it only goes to true if the value has been loaded successfully.
@mikerowehl mikerowehl force-pushed the recipe-read-issuccess branch from 89a156c to da8d070 Compare December 22, 2025 17:37
@mikerowehl
Copy link
Author

Rebased on top of the vocs changes to update the way the code highlighting is done. The vocs update looks to have also added a few pairs of curly braces to the final example showing the loading state, which made it inconsistent with the view of the whole example at the top of the page. I believe that version might have actually been syntactically invalid. I think this version should clean that up, but I'm not sure if there was something else that was trying to work around. Let me know if it doesn't render correctly. I'm seeing what looks like a good version when I do a preview locally.

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.

1 participant