mirror of
https://github.com/status-im/react-native.git
synced 2025-01-17 04:50:59 +00:00
e11d496e9d
Summary: Follow up to 9ec95673909beac7798f589e0e9821b4225f8fa9 Closes https://github.com/facebook/react-native/pull/16759 Differential Revision: D6285219 Pulled By: hramos fbshipit-source-id: 7012d257a5a6cff06cb2d94203a9379e4b7e3c4e
1.8 KiB
1.8 KiB
id | title | layout | category | permalink | next | previous |
---|---|---|---|---|---|---|
layoutanimation | LayoutAnimation | docs | APIs | docs/layoutanimation.html | linking | keyboard |
Automatically animates views to their new positions when the next layout happens.
A common way to use this API is to call it before calling setState
.
Note that in order to get this to work on Android you need to set the following flags via UIManager
:
UIManager.setLayoutAnimationEnabledExperimental && UIManager.setLayoutAnimationEnabledExperimental(true);
Methods
Properties
Reference
Methods
configureNext()
LayoutAnimation.configureNext(config, onAnimationDidEnd?)
Schedules an animation to happen on the next layout.
@param config Specifies animation properties:
duration
in millisecondscreate
, config for animating in new views (seeAnim
type)update
, config for animating views that have been updated (seeAnim
type)
@param onAnimationDidEnd Called when the animation finished. Only supported on iOS. @param onError Called on error. Only supported on iOS.
create()
LayoutAnimation.create(duration, type, creationProp)
Helper for creating a config for configureNext
.
checkConfig()
LayoutAnimation.checkConfig(config, location, name)