title: Center Activity Indicator with absolute position in React Native
body: <p>i am using View overlay and ActivityIndicator to hide loading map in the background. The solution i am using is View with absolute position to make it on top of everything and putting activityindicator on top, so there is something happening.
   The issue is, that because the ActivityIndiator size cant be set to specific pixels on iOS, i dont know what is its size and thus i cant center it properly. Or i didnt figure out way to do it.</p>
  
  <p>Here is some code:</p>
  
  <pre><code>&lt;View style={styles.whiteOverlay}&gt;
        &lt;ActivityIndicator style={styles.indicator} size="large" color={colors.color4} /&gt;
   &lt;/View&gt;
  
   whiteOverlay: {
          width: screen.height,
          height: screen.height,  
          backgroundColor: 'white',
          position: 'absolute',     
          zIndex: 20        
      },
      indicator: {
          zIndex: 21,
          position: 'absolute',
          left: screen.width/2,
          top: screen.height/2        
      }
  </code></pre>
  
  <p>This positions the indicator offseted from center. I can put there some magic numbers to make it work for a specific device, guessing the size of the indicator, but it then doesnt work on other devices. Thanks for any help.</p>