Skip to content

[BUG] useSpring won't work properly when initial value is 0 #23

@yaquawa

Description

@yaquawa

Reproduce link:
https://codesandbox.io/s/vueusemotion-forked-9zzt7?file=/src/components/Person.vue

Steps to reproduce

  1. click "to 100"
  2. click "to 0"
  3. click "to 100" again

You'll notice that the first time when you click the "to 100" button, the animation won't take effect.
But if you set the initial value to anything number except for 0, it works...

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions