Check out example codes for "how to vertically align text css". It will help you in understanding the concepts better.

Code Example 1

<!DOCTYPE html>
<html>
  <head>
    <title>Title of the document</title>
    <style type="text/css">
      div {
        display: table-cell;
        width: 250px;
        height: 200px;
        vertical-align: middle;
      }
    </style>
  </head>
  <body>
    <div>Vertically aligned text</div>
  </body>
</html>

Code Example 2

.center {
  padding: 70px 0;
  border: 3px solid 
green;
  text-align: center;

}

Code Example 3

.parent {
  position: relative;
}
.child {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
}

Learn ReactJs, React Native from akashmittal.com