This is a
playground to test code. It runs a full
Node.js environment and already has all of
npm’s 1,000,000+ packages pre-installed, including
soundrecorder with all
npm packages installed. Try it out:
This service is provided by RunKit and is not affiliated with npm, Inc or the package authors.
SoundRecorder is a website sound recorder SDK base on h5 api.
SoundRecorder build by umd, you can use it by 2 ways:
<script src="/dist/soundRecorder.min.js"></script>tag into the html.
SoundRecorder is very easy to use, You can read the full demo here or read the code
// 1. instance the SoundRecorder var sr = new SoundRecorder() // 2. start sr.start() // 3. stop sr.stop() // 4. get the recorded file var blob = sr.getBlob() console.log(blob)
there the methods of SoundRecorder instance
description: start mediaRecorder
description: stop mediaRecorder
description: get recorded blob, the blob is build by all chunks
description: add the event listener callback