Skip to content

Instantly share code, notes, and snippets.

@caldofran
Created March 6, 2020 15:37
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save caldofran/11bf959eeca7940aa85f239b3c793721 to your computer and use it in GitHub Desktop.
Save caldofran/11bf959eeca7940aa85f239b3c793721 to your computer and use it in GitHub Desktop.
Screen extensions
extension Screen {
static func offer(id: String) -> Self {
return .init() { OfferViewController(id: id) }
}
}
extension Screen {
static func job(id: String) -> Self {
return .init() { JobViewController(id: id) }
}
}
extension Screen {
static func document(url: URL) -> Self {
return .init() { DocumentViewController(url: url) }
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment