Skip to content

Instantly share code, notes, and snippets.

@peteranny
Last active July 29, 2020 17:41
Show Gist options
  • Save peteranny/47852ad83897d9c69d70dd7c1195579a to your computer and use it in GitHub Desktop.
Save peteranny/47852ad83897d9c69d70dd7c1195579a to your computer and use it in GitHub Desktop.
public class HelloWorld {
let greet = "Hello"
public init() {}
public func hello(to whom: String) -> String {
return "\(greet) \(whom)"
}
public var helloColor: UIColor? {
if #available(iOS 11.0, *) {
return UIColor(named: "HelloColor", in: Bundle(for: HelloWorld.self), compatibleWith: nil)
} else {
return nil
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment