When using the audio control, the play() request will be interrupted by pause
The specific solutions are as follows:
Before judging whether the audio is playing, the load () method should be called to load the audio data;
Then the audio is judged by if, and then the playback or pause is processed asynchronously
Play or pause after successful callback, depending on business requirements;
Read More:
- DOMException: play() failed because the user didn‘t interact with the document first
- Chrome console reports Failed to load resource: net::ERR_BLOCKED_BY_CLIENT one of the solutions
- Remove video with video byte 0, uncaught (in promise) domexception: failed to load because no supported source was f
- C + + uses system (“pause”) to pause black windows
- Solve the problem of error running console reported by pycharm Python console
- Resolve Audio: failed to create voice ` goldfish_ Audio ‘error
- Easywasmlayer reports an error uncaught (in promise) domexception when playing a video
- Interrupted function call accept failed when idea starts Tomcat
- An error is reported when starting the Android emulator: Emulator: audio: Failed to create voice `goldfish_audio_in’
- C + + pauses the black window system (“pause”); (get ch(), getchar(), system (pause)’s connection and difference
- [solution] Google Chrome browser hijacked by hao123 chrome://version Command line tampered
- Playing audio in termux
- Video JS can’t play the prompt( CODE:4 MEDIA_ ERR_ SRC_ NOT_ SUPPORTED) No compatible source was found for this video.
- Invalid chrome console
- Python Anaconda Spyder can’t display pictures by using Matplotlib. Error report solution: figures now render in the plots pane by default. To mak
- Usage of pause function in MATLAB
- 12 days after the programmer was dismissed by the company, the former leader asked to go back to the company to explain the code clearly, but he was confused
- Camtasia | An error occurred in the Recorde System Audio setup Failed
- How to convert audio to subtitle (text) with Python?
- Solve the problem that data cannot be input in idea console