Check out example codes for "css border opacity". It will help you in understanding the concepts better.

Code Example 1

div {
    border: 1px solid rgba(255, 0, 0, .5);
    -webkit-background-clip: padding-box; /* for Safari */
    background-clip: padding-box; /* for IE9+, Firefox 4+, Opera, Chrome */
}

Code Example 2

border: 1px solid rgba(255, 0, 0, .5);

Learn ReactJs, React Native from akashmittal.com