Created
October 27, 2019 04:05
-
-
Save wanderingmatt/2bf8fd78bd5ae125050cfabf2b9542bb to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
let colors: [String] = [ | |
"Blue", | |
"Green", | |
"Orange", | |
"Purple", | |
"Red", | |
"Yellow" | |
] | |
func randomBackgroundColor() -> Color? { | |
if let color = colors.randomElement() { | |
return Color(color) | |
} | |
return nil | |
} |
kennymeyers
commented
Oct 27, 2019
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment