Skip to content

Instantly share code, notes, and snippets.

@seanblanton
Created July 13, 2017 18:56
  • Select an option

Select an option

rgb(a) alpha value override function
# Overrides rgba alpha values with a new alpha
const alpha = (color, opacity) =>
color.replace(/[\d\.]+\)$/g, opacity+')')
alpha(gray100, 0.4)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment