Check out example codes for "rgb purple color". It will help you in understanding the concepts better.

Code Example 1

(128,0,128)    Hex  #800080

Learn ReactJs, React Native from akashmittal.com