title: Repeat animation with new animated api
body: <p>React-native introduce new <code>Animated</code> API, I want to make a loop animation such as a bubble scale up then scale down and repeat that progress.</p>
  
  <p>However I can not figure it out. I've tried write some code like below</p>
  
  <pre><code>class TestProject extends React.Component {
  
    constructor(): void {
      super();
      this.state = {
        bounceValue: new Animated.Value(0),
        v: 1,
      };
    }
  
    componentDidMount() {
      this.state.bounceValue.setValue(1.5);
  
      let animation = Animated.timing(this.state.bounceValue, {
        toValue: this.state.v,
      });
  
      setInterval(() =&gt; {
        animation.stop();
  
        if (this.state.flag) {
          this.state.v = 0.5;
          this.state.bounceValue.setValue(0.5);
        }
        else {
          this.state.v = 1.5;
          this.state.bounceValue.setValue(1.5);
        }
  
        animation.start();
      }, 5000);
  
    }
  
    render(): ReactElement {
      return (
        &lt;View style={styles.imageContainer}&gt;
          &lt;Image
            style={styles.image}
            source={{uri: 'http://image142-c.poco.cn/best_pocoers/20130517/91062013051716553599334223.jpg'}}
          /&gt;
          &lt;Animated.Text
            style={[
              styles.test,
              {transform: [
                {scale: this.state.bounceValue},
              ],}
            ]
            }&gt;
            haha
          &lt;/Animated.Text&gt;
        &lt;/View&gt;
      );
    }
  
  }
  </code></pre>
  
  <p>but not works very well.</p>
  
  <p>Any suggestion will be appreciate.</p>