react-spring icon indicating copy to clipboard operation
react-spring copied to clipboard

[bug]: `useTransition` with boolean item and function config doesn't animate since `9.5.2`

Open jordanoverbye opened this issue 2 years ago • 0 comments

Which react-spring target are you using?

  • [X] @react-spring/web
  • [ ] @react-spring/three
  • [ ] @react-spring/native
  • [ ] @react-spring/konva
  • [ ] @react-spring/zdog

What version of react-spring are you using?

9.7.1

What's Wrong?

When using useTransition, if you pass in a boolean as the first argument and a function as the second argument, the transitions do not run as expected.

This syntax use to work in previous versions up until version 9.5.2, where it's suddenly stopped working.

To Reproduce

Code sandbox which demonstrates the issue https://codesandbox.io/s/little-voice-5hl8w6?file=/src/App.tsx

Expected Behaviour

If this syntax is not valid, I would expect to see some Typescript errors.

If it is valid syntax, I expect the transitions to run as expected.

Link to repo

https://codesandbox.io/s/little-voice-5hl8w6?file=/src/App.tsx

jordanoverbye avatar Jul 25 '23 03:07 jordanoverbye