Search Header Logo
Modern JavaScript from the Beginning - Second Edition - Speech Synthesis API - Text to Speech

Modern JavaScript from the Beginning - Second Edition - Speech Synthesis API - Text to Speech

Assessment

Interactive Video

Computers

9th - 10th Grade

Practice Problem

Hard

Created by

Wayground Content

FREE Resource

The video tutorial covers the implementation of a web-based text-to-speech application using the Web Speech API. It begins with setting up a simple HTML form and then moves on to initializing JavaScript variables and functions for speech synthesis. The tutorial demonstrates how to submit text input and select different voices for speech output. It also includes testing various voice options and discusses the potential applications for non-verbal communication tools.

Read more

10 questions

Show all answers

1.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What is the purpose of the form element in the HTML structure?

To display the available voices

To allow users to input text

To style the page

To initialize the JavaScript

2.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which JavaScript object is used to handle speech synthesis?

window.speechSynthesis

window.speechRecognition

window.voiceControl

window.textToSpeech

3.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What is the role of the 'speak' function in the JavaScript code?

To convert text to speech

To log text to the console

To initialize the form

To change the voice

4.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

How is the text input captured for speech synthesis?

Using document.createElement

Using document.getElementById

Using document.addEventListener

Using document.querySelector

5.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What is the purpose of the 'addVoicesToSelect' function?

To log the available voices

To change the language of the voices

To populate the select box with voice options

To initialize the speech synthesis

6.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which method is used to retrieve available voices in the JavaScript code?

synth.loadVoices()

synth.retrieveVoices()

synth.getVoices()

synth.fetchVoices()

7.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What attribute is set to identify the language of a voice?

data-speech

data-voice

data-lang

data-language

Access all questions and much more by creating a free account

Create resources

Host any resource

Get auto-graded reports

Google

Continue with Google

Email

Continue with Email

Classlink

Continue with Classlink

Clever

Continue with Clever

or continue with

Microsoft

Microsoft

Apple

Apple

Others

Others

Already have an account?