I have a problem with speech recognition integration into webchat. This is the code I use. It´s just the same code like here: https://github.com/microsoft/BotFramework-WebChat/blob/master/SPEECH.md#integrating-web-chat-into-your-page
But I always get the error: Uncaught SyntaxError: Unexpected identifier at line...
and line of error is: webSpeechPonyfillFactory: await createSpeechRecognitionOnlyPonyfillFactory({
Without speech recognition it´s all working. Do you have some idea?
const { createCognitiveServicesSpeechServicesPonyfillFactory, createDirectLine, renderWebChat } = window.WebChat;
const styleOptions = {
botAvatarInitials: 'Bot',
userAvatarInitials: 'You'
};
renderWebChat(
{
directLine: createDirectLine({
secret: 'FFFFFFFFFFFFFFFF'
}),
language: 'de-DE',
webSpeechPonyfillFactory: await createSpeechRecognitionOnlyPonyfillFactory({
region: 'westeurope',
subscriptionKey: 'FFFFFFFFFFFFFFFFFFFFFF'
}),
styleOptions
},
document.getElementById('webchat')
);
document.querySelector('#webchat > *').focus();