From 4c6dece09c6cc0b9b010670408bd395759dc3a77 Mon Sep 17 00:00:00 2001 From: Eli White Date: Wed, 20 Jun 2018 23:47:40 -0700 Subject: [PATCH] Animated Example using Image Summary: Need to test a potential issue with Animated.Image on Android. Adding a RNTester example to exercise it. Reviewed By: yungsters Differential Revision: D8559440 fbshipit-source-id: 4319d958de146c177cb0bd4b84679b773ce50833 --- RNTester/js/AnimatedExample.js | 53 ++++++++++++++++++++++++++++++++++ 1 file changed, 53 insertions(+) diff --git a/RNTester/js/AnimatedExample.js b/RNTester/js/AnimatedExample.js index d11cbef52..490f70371 100644 --- a/RNTester/js/AnimatedExample.js +++ b/RNTester/js/AnimatedExample.js @@ -222,6 +222,59 @@ exports.examples = [ ); }, }, + { + title: 'Rotating Images', + description: 'Simple Animated.Image rotation.', + render: function() { + this.anim = this.anim || new Animated.Value(0); + return ( + + { + Animated.spring(this.anim, { + toValue: 0, // Returns to the start + velocity: 3, // Velocity makes it move + tension: -10, // Slow + friction: 1, // Oscillate a lot + }).start(); + }}> + Press to Spin it! + + + + ); + }, + }, { title: 'Continuous Interactions', description: