tchvu3 / capacitor-voice-recorder

Capacitor plugin for voice recording
69 stars 57 forks source link

How to prompt user for permission in order to avoid `MISSING_PERMISSION` error? #32

Closed mepc36 closed 1 year ago

mepc36 commented 1 year ago

Hey there, great lib, thanks for making it.

How do I prompt the user for permission to record in order to avoid the MISSING_PERMISSION error? Do I have to manually bring up that prompt by calling a method on the VoiceRecording object? Or should Android/iOS just do it automatically once it detects permissions in the AndroidManifest.xml/Info.plist?

If the case is the latter, then what permissions do we need to add in order to voice record?

mepc36 commented 1 year ago

Sorry, answer is right in the docs, my bad:

VoiceRecording.requestAudioRecordingPermission.