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

conditional fetching with onSpringStart it make glitching issue or ropen twice the bottomsheet #267

Open
wibawasuyadnya opened this issue May 30, 2023 · 2 comments

Comments

@wibawasuyadnya
Copy link

wibawasuyadnya commented May 30, 2023

when !data && isLoading i have different element and it has Skeleton for Callback if my data is not fetched already
but when it finish fetching the bottomsheet close it self and reopen again with the fetched data.
does anyone know how to handle this ?
ps :
i already do anything async axios get inside the onSpringStart and now I still stick with my useSWR with fetcher async axios.get function and define function Promise and call them with await inside the onSpringStart but it still presist on first or initial load i click on bottomsheet it was open like I just say earlier with isLoading or the Callback but when it finish fetched it close and reopen again quickly and this is really annoy me sorry but thanks cool package though btw I just want the bottomsheet just still open even my data isn't fully fetched or waiting for fetch successed just like inside page normally

@wibawasuyadnya
Copy link
Author

wibawasuyadnya commented May 30, 2023

I really need help, again thanks guys have a nice day

@flickleafy
Copy link

I just discovered that you can send a callback to fetch data inside the body of the modal. and inside there, it can run the loading animation while it calls the api, and then replace that to the actual content... that worked for me.

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

2 participants