Skip to content

Instantly share code, notes, and snippets.

View williamallenmd's full-sized avatar

William Allen williamallenmd

View GitHub Profile
@EnesKaraosman
EnesKaraosman / RandomColor.swift
Last active May 9, 2024 22:41
Generatin random color in SwiftUI & UIKit
#if canImport(UIKit)
import UIKit
extension UIColor {
static var random: UIColor {
return UIColor(
red: .random(in: 0...1),
green: .random(in: 0...1),
blue: .random(in: 0...1)
)