content: 
  import React, { Component } from 'react';
  import { ActivityIndicator, StyleSheet, View } from 'react-native';
  
  /**
   * Optional Flowtype state and timer types definition
   */
  type State = { animating: boolean; };
  type Timer = number;
  
  export default class ActivityIndicatorLoader extends Component {
    /**
     * Optional Flowtype state and timer types
     */
    state: State;
    _timer: Timer;
  
    constructor(props) {
      super(props);
      this.state = {
        animating: true,
      };
    }
  
    componentDidMount() {
      this.setToggleTimeout();
    }
  
    componentWillUnmount() {
      clearTimeout(this._timer);
    }
  
    setToggleTimeout() {
      this._timer = setTimeout(() => {
        this.setState({animating: !this.state.animating});
        this.setToggleTimeout();
      }, 2000);
    }
  
    render() {
      return (
        <ActivityIndicator
          animating={this.state.animating}
          style={[styles.centering, {height: 80}]}
          size="large"
        />
      );
    }
  }
  
  const styles = StyleSheet.create({
    centering: {
      alignItems: 'center',
      justifyContent: 'center',
      padding: 8,
    },
    gray: {
      backgroundColor: '#cccccc',
    },
    horizontal: {
      flexDirection: 'row',
      justifyContent: 'space-around',
      padding: 8,
    },
  });
  