React-native-animatable: this._transforms.forEach in not a function when setting a (non animated) transform on an animated image

Created on 10 Jan 2017  路  2Comments  路  Source: oblador/react-native-animatable

I'm setting a transform: translation on an Animated.Image, but animatable crashes:

Unhandled JS Exception: this._transforms.forEach is not a function. (In 'this._transforms.forEach', 'this._transforms.forEach' is undefined)

AnimatedImplementation.js:1408

Most helpful comment

In case anyone else is having this issue, you need to declare the transform property you want to animate, not the "transform" property.
For this: style={{transform: ['scale': ...]}}
This: transition="scale"
Not this: transition="transform"
This should be in the docs somewhere, or at least an example.

All 2 comments

It was an error on my side

In case anyone else is having this issue, you need to declare the transform property you want to animate, not the "transform" property.
For this: style={{transform: ['scale': ...]}}
This: transition="scale"
Not this: transition="transform"
This should be in the docs somewhere, or at least an example.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

TrustDec picture TrustDec  路  3Comments

kamek-pf picture kamek-pf  路  8Comments

ggomaeng picture ggomaeng  路  5Comments

Aspirationtocode picture Aspirationtocode  路  7Comments

HananeAlSamrout picture HananeAlSamrout  路  3Comments