Skip to main content
Deno 2 is finally here 🎉️
Learn more
Module

x/colors/src/mod.ts>max

Color conversion and stuff in TypeScript
Latest
function max
import { max } from "https://deno.land/x/colors@v2.0.2/src/mod.ts";

Get maximum of r, g, b, a, scaled to [0, 1].

Parameters

color: Color3 | Color4

An array of RGB or RGBA values.

Returns

number

The maximum value in the array scaled to [0, 1].