On this tutorial I will be demonstrating how to match the hex value to the Regex. Regular Expressions or Regex for short is a sequence of characters that match a pattern in the text. The regex usually looks like gibberish, but it is a very useful tool to have in your toolbox.
I will be demonstrating how to evaluate regex to match hex values.
Our example of code is /^#?([a-f0-9]{6}|[a-f0-9]{3})$/