-
-
Notifications
You must be signed in to change notification settings - Fork 12
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
Waiting before screenshot #74
Comments
Hi @JavierM42, what kind of animations are you dealing with? If they're CSS, I'd recommend importing an extra CSS file that disables them. If you can share a code sample, that'd be appreciated! |
We're using Framer Motion. If you try to screenshot something like this, the resulting screenshot never gets the same opacity.
We could add an environment variable to conditionally set I guess that a better solution would be to add a delay before taking the screenshot, but I'm not sure if/how we can do that with Viteshot. |
Cheers for the extra context. I can think of a couple of approaches:
If it works, the former would be better as it won't slow down your screenshots and wouldn't require extra boilerplate. Let me know how you go. |
I tried the motion config yesterday, it only stops transforms that actually move elements (translateX, translateY, rotate, ...), opacity isn't affected. I'll try the timeout tomorrow and get back to you, thanks! |
Timeout works great! Thanks a lot @fwouts Awesome tool btw 🎉, I even wrote a blog post about it. It's been a massive improvement to our workflow. |
Awesome @JavierM42, thanks for the article! I wonder if you've seen the |
We are having issues with components that have mount animations. Since we don't know how to wait for them to finish, our screenshots are slightly different every time.
Is it possible to solve it with
beforeScreenshot
?The text was updated successfully, but these errors were encountered: