Skip to content

Instantly share code, notes, and snippets.

@katiesmillie
Created October 26, 2016 20:08
Show Gist options
  • Save katiesmillie/66d77cde3be63f97f5986dabdf643df4 to your computer and use it in GitHub Desktop.
Save katiesmillie/66d77cde3be63f97f5986dabdf643df4 to your computer and use it in GitHub Desktop.
func tappedFacebook(sharingOptionsView: SharingOptionsView) {
Analytics().track(event: "Share Facebook")
guard let imageToShare = makeCompositeToShare() else { return }
let photo = FBSDKSharePhoto()
photo.image = imageToShare
photo.isUserGenerated = true
let content = FBSDKSharePhotoContent()
content.photos = [photo]
FBSDKShareDialog.show(from: self, with: content, delegate: nil)
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment