Skip to content

Instantly share code, notes, and snippets.

@NunoAlexandre
Last active December 23, 2018 10:53
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 NunoAlexandre/482adc37420b713b32bb665f3565dffc to your computer and use it in GitHub Desktop.
Save NunoAlexandre/482adc37420b713b32bb665f3565dffc to your computer and use it in GitHub Desktop.
Create Slideshow - Typed Modeling
let slides = [
Slide(
title: "Bobby Mcferrin",
description: "Jazz at its best",
image: UIImage(name: "BobbyMcferrin")!
),
Slide(
title: "Kurt Vile",
description: "A prolific creative",
image: UIImage(name: "KurtVile")!
),
Slide(
title: "The War on Drugs",
description: "An American indie rock band from Philadelphia",
image: UIImage(name: "TheWarOnDrugs")!
)
]
let slideViews = slides.map(SlideView.init(slide:))
let slideshow = Slideshow(slides: slideViews)!
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment