Transition with unmount
See original GitHub issueWhat package within Headless UI are you using?
@headlessui/react
What version of that package are you using?
v1.6.4
What browser are you using?
Chrome
Reproduction URL
sandbox: codesandbox.io/s/objective-noether-9qi5ri?file=/src/App.js
Describe your issue
Transition
component with unmount
prop does not play animation when called from a completely inactive state as expected, but if another animation is played in parallel - it works fine
Issue Analytics
- State:
- Created a year ago
- Reactions:8
- Comments:11
Top Results From Across the Web
React - animate mount and unmount of a single component
I think using Transition from react-transition-group is probably the easiest way to track mounting/unmounting. It is incredibly flexible.
Read more >Animating unMount in React with CSS3 transitions - Medium
The problem with animating react components with css3 transitions is that react with unMount your component before the animation is done.
Read more >Super easy react mount/unmount animations with hooks
As soon as the animation finishes, unmount the component. I want to show you the simplest way to accomplish this using pure CSS...
Read more >React Showtime: Mount and Unmount with CSS Transitions
It automatically handles mounting and unmounting to allow time for transitions to occur. See the Github repository here: ...
Read more >How to animate mount and unmount of a react component ...
In this video we add animations to the mount and unmount events of a react component using the react-spring animation library and hooks, ......
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
After refreshing my browser a lot of times, I could reproduce it about 1-2% of the time in Chrome and was still very random. Could not reproduce it in Safari at all, I could reproduce it in Firefox pretty consistently.
But I think I found a solution here #1811
@ARkrOSClou can you install the latest insiders version and see if that works on your machine now?
Perfect, I’m really happy to read this. In a previous version we did some important updates to Transition, but this particular bug was related to the
unmount={false}
directly.Glad it’s fixed now! Thank you for testing.