Skip to content

Instantly share code, notes, and snippets.

@acotilla91
Last active May 31, 2018 06:21
Show Gist options
  • Save acotilla91/2fc07f1f346a6cf5c06b28b8a47a4a13 to your computer and use it in GitHub Desktop.
Save acotilla91/2fc07f1f346a6cf5c06b28b8a47a4a13 to your computer and use it in GitHub Desktop.
AVSpeechSynthesizer | Text-to-Speech | iOS
let synth = AVSpeechSynthesizer()
let utterance = AVSpeechUtterance(string: "Some text")
let voice = AVSpeechSynthesisVoice(language: "en-US")
synth.speak(utterance)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment