Check out example codes for "add gradient to text css". It will help you in understanding the concepts better.

Code Example 1

h1 {
  font-size: 72px;
  background: -webkit-linear-gradient(#eee, #333);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

Learn ReactJs, React Native from akashmittal.com