Skip to content

Instantly share code, notes, and snippets.

@arthur-here
Created July 13, 2017 07:29
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 arthur-here/48129113ef2edcab038cc748d8f8f223 to your computer and use it in GitHub Desktop.
Save arthur-here/48129113ef2edcab038cc748d8f8f223 to your computer and use it in GitHub Desktop.
class RepositoryViewModel {
let name: String
let description: String
let starsCountText: String
let url: URL
init(repository: Repository) {
self.name = repository.fullName
self.description = repository.description
self.starsCountText = "⭐️ \(repository.starsCount)"
self.url = URL(string: repository.url)!
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment