Quantcast
Channel: Active questions tagged javascript - Stack Overflow
Viewing all articles
Browse latest Browse all 140331

Create a list of elements

$
0
0

I want to create a list of recognized notes, but have an issue to do this. The note just changing one to another one.

index.html

<p id="message"></p>

app.js

var message = document.querySelector('#message');

song.addEventListener('ended', ()=>{
    recognition.onresult = function(event) {
        var last = event.results.length - 1;
        var command = event.results[last][0].transcript;
        message.textContent = command + '.'; 
    }
    recognition.start();
})

Viewing all articles
Browse latest Browse all 140331

Latest Images

Trending Articles



Latest Images

<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>