Important: This documentation covers Yarn 1 (Classic).
For Yarn 2+ docs and migration guide, see yarnpkg.com.

Package detail

web-audio-wave-recorder

tlvince288MIT1.0.15

Record wav files using Web Audio APIs

audio, wav, wave, microphone

readme

web-audio-wave-recorder

Record wav files using Web Audio APIs

Unfortunately, MediaRecorder does not support wav files (technically linear PCM encoding). This uses the older and less fluent AudioContext API, manually dealing with audio buffers and .wav header construction.

API

start(options: RecordingOptions): Promise<RecordingState>

Takes optional recording options and starts recording.

stop(recordingState: RecordingState): Promise<Blob>

Takes required recording state and returns a blob of type audio/wav.

Prior art

Author

© 2019 Tom Vincent git@tlvince.com (https://tlvince.com)

License

Released under the MIT license.