IFClite TypeScript API
    Preparing search index...

    Function colorForUser

    • Pick a deterministic color from palette for the given user id.

      Same id + same palette → same color, always. Different palettes pick different colors for the same id, which is what consumers want when they bring their own brand palette.

      Parameters

      • userId: string
      • Optionalpalette: readonly string[]

      Returns string