JavaScript
const utterance = new SpeechSynthesisUtterance('Hello World');
speechSynthesis.speak(utterance);Output
// Speaks "Hello World"
Speech Synthesis converts text to speech.
Convert text to speech
const utterance = new SpeechSynthesisUtterance('Hello World');
speechSynthesis.speak(utterance);// Speaks "Hello World"
Speech Synthesis converts text to speech.