-2

i wanted to know that how to produce a sound effect after read code successfully in Javascript. For example when we are scan the qr code, then it would come out sound such as "beep".

1 Answers1

0

Create a function:

    function beep() {
    let sound = new Audio("audio.mp3");  
    sound.play();
 }
    beep();
debugger
  • 1,442
  • 1
  • 9
  • 14