motiondivision / motion

A modern animation library for React and JavaScript
https://motion.dev
MIT License
25.67k stars 843 forks source link

[BUG] Exit animation with Next.js #2674

Open asd58584388 opened 6 months ago

asd58584388 commented 6 months ago

1. Read the FAQs 👇

2. Describe the bug

when clicking accordion item rapidly, the accordion item display incorrectly.

3. IMPORTANT: Provide a CodeSandbox reproduction of the bug

codesandbox

4. Steps to reproduce

Click accordion item rapidly

5. Expected behavior

accordion items close and expand correctly

6. Video or screenshots

image Delete the key attribute solve this problem, but I don't know why

The component trees: image

https://github.com/framer/motion/assets/43491476/3a20620b-a1cb-4eda-92a5-40565a6c5bc6

farhadham commented 6 months ago

Can you try giving a unique key to each <motion.section> and also giving key to each mapped words and paraghraphs

asd58584388 commented 5 months ago

still not working

ansonchaan commented 1 month ago

Same issue! Please fix it!