Sass green() Function

Last Updated:

Sass green() Function

The green() function returns the green channel of a given color as a number between 0 and 255.

Example

SASS TO CSS CONVERTER
//Check your console @debug green(#e1d7d2); // 215 @debug green(white); // 255 @debug green(black); // 0

Syntax

green($color)

Parameter Value

ValueTypeExplanation
$color Required Specifies a color.

Return Value

ValueExplanation
Number Returns the green channel of $color as a number between 0 and 255.

Share this Page

Meet the Author