expo-speech-recognition 3.1.0 → 3.1.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +6 -0
- package/README.md +1 -1
- package/ios/ExpoSpeechRecognizer.swift +5 -0
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
package/README.md
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# 🎙️ expo-speech-recognition
|
|
2
2
|
|
|
3
|
-

|
|
3
|
+
[](https://www.npmjs.com/package/expo-speech-recognition)
|
|
4
4
|
|
|
5
5
|
expo-speech-recognition implements the iOS [`SFSpeechRecognizer`](https://developer.apple.com/documentation/speech/sfspeechrecognizer), Android [`SpeechRecognizer`](https://developer.android.com/reference/android/speech/SpeechRecognizer) and Web [`SpeechRecognition`](https://wicg.github.io/speech-api/) for React Native projects with the goal of code reuse across web and mobile.
|
|
6
6
|
|
|
@@ -782,6 +782,11 @@ actor ExpoSpeechRecognizer: ObservableObject {
|
|
|
782
782
|
let newEngine = AVAudioEngine()
|
|
783
783
|
let inputNode = newEngine.inputNode
|
|
784
784
|
let audioFormat = Self.getAudioFormat(forEngine: newEngine)
|
|
785
|
+
|
|
786
|
+
guard !Self.audioInputIsBusy(audioFormat) else {
|
|
787
|
+
return false
|
|
788
|
+
}
|
|
789
|
+
|
|
785
790
|
let mixerNode = AVAudioMixerNode()
|
|
786
791
|
newEngine.attach(mixerNode)
|
|
787
792
|
newEngine.connect(inputNode, to: mixerNode, format: audioFormat)
|