📎 Webclip
HTML5: record audio to file
The answer references an existing web demo that records audio directly in the browser and then lets the user export and download the recorded sound. By inspecting that demo’s source, one can see a JavaScript Recorder object that offers methods to export the recording as a WAV file and to initiate a download of the result.
Reading notes#
- A browser-based audio recording demo is available at
http://webaudiodemos.appspot.com/AudioRecorder/index.html. - The demo lets users record audio in the browser, then export and download what was recorded.
- Viewing the page source reveals JavaScript code with a
Recorderobject. - The
Recorderobject includes anexportWAVmethod for creating a WAV file from the recording. - The
Recorderobject also provides aforceDownloadmethod to start downloading the exported audio file.
