When switching to a new url, the animation in the new url does not start from the beginning. You can see this in the logs:
Steps To Reproduce
Steps to reproduce the behavior:
Copy above code into sample app.
Run, observe animations not starting from start frames when tapping change animation button & in logs
Additional info
The main issue seems to be not being able to trigger this inside animateLottieCompositionFromState
if (isPlaying && !wasPlaying && restartOnPlay) {
animatable.resetToBeginning()
}
For now you can workaround this by wrapping the entire block with a key, as remember doesn't work due to lottie holding onto these states via remember {} functions
Minimal example to reproduce:
Describe the bug
When switching to a new url, the animation in the new url does not start from the beginning. You can see this in the logs:
Steps To Reproduce Steps to reproduce the behavior:
Additional info
The main issue seems to be not being able to trigger this inside animateLottieCompositionFromState
For now you can workaround this by wrapping the entire block with a key, as remember doesn't work due to lottie holding onto these states via
remember {}
functions