Update RGBToHex.md
This commit is contained in:
committed by
GitHub
parent
8b91be9e2f
commit
74832b19a7
@ -3,7 +3,7 @@ title: RGBToHex
|
||||
tags: string,math,intermediate
|
||||
---
|
||||
|
||||
Converts the values of RGB components to a color code.
|
||||
Converts the values of RGB components to a hexadecimal color code.
|
||||
|
||||
Convert given RGB parameters to hexadecimal string using bitwise left-shift operator (`<<`) and `toString(16)`, then `String.padStart(6,'0')` to get a 6-digit hexadecimal value.
|
||||
|
||||
|
||||
Reference in New Issue
Block a user