Check out example codes for "how to center all elements in a linearlayout". It will help you in understanding the concepts better.

Code Example 1

android:gravity takes care of its children,
android:layout_gravity takes care of itself

Learn ReactJs, React Native from akashmittal.com