React-native-reanimated: [V2] Animation triggers inconsistently - Parallel/Sequence

Created on 18 Jul 2020  路  3Comments  路  Source: software-mansion/react-native-reanimated

Description

I was playing around with V2-playground and I've stumbled upon a bug.
I was trying to change the background color of the view with an animation that should run parallel to the change in width.

  • If both of the values (width & color) reside in the same useAnimatedStyle hook (styleA) then the animation runs in sequence.
  • If I split the values to 2 different useAnimatedStyle hooks (styleB, styleC) then the animation runs in parallel, as expected.
  • However, if both width & height values reside in the same useAnimatedStyle hook (styleD) the animation runs in parallel, as expected.

See styleA, styleB, styleC, styleD in App.js
TESTED on ANDROID only!


r2gif

Steps To Reproduce

  1. Follow ShaMan123/reanimated-2-playground README.
  2. Run the app.

Expected behavior

Both animations should run parallel to each other

Actual behavior

See gif

Snack or minimal code example

Provided a repo, snack caused problems

Package versions

package.json

馃彔 Reanimated2 馃悶 Bug

Most helpful comment

FIXED!

All 3 comments

Could you check if the issue still persists? We have solved a similar problem and the solution is already in alpha.4 version.

I'll Check and report back

FIXED!

Was this page helpful?
0 / 5 - 0 ratings