Welcome to the Treehouse Community
Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community!
Looking to learn something new?
Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.Start your free trial
Osama Mansour1,411 Points
when do i use the rgba ?
what does the percentage or the decimal number in the rgba function do to the color? when do i use the rgba function ? what is the difference between rgba and rgb?
Walter AlleniOS Development with Swift Techdegree Student 16,023 Points
In rgba and rgb, the 'r' stands for 'red,' the 'g' stands for 'green,' and the 'b' stands for blue. In rgba, the 'a' stands for 'alpha.' What the alpha value does is create an opacity or transparency for the color. For example, and alpha value of 1 is completely opaque, while an alpha value of 0 is complete transparent. A value in between, i.e. .5, or 50%, is half-transparent.
Does that help? You can read more here: https://developer.mozilla.org/en-US/docs/Web/CSS/color_value#rgba.