Open waymond91 opened 11 months ago
eas.json :
{
"cli": {
"version": ">= 5.9.0"
},
"build": {
"development": {
"developmentClient": true,
"distribution": "internal"
},
"preview": {
"distribution": "internal"
},
"preview2": {
"android": {
"gradleCommand": ":app:assembleRelease"
}
},
"production": {}
},
"submit": {
"production": {}
}
}
app.json :
{
"expo": {
"name": "LoginApp",
"slug": "LoginApp",
"version": "1.0.0",
"orientation": "portrait",
"icon": "./assets/icon.png",
"userInterfaceStyle": "light",
"splash": {
"image": "./assets/splash.png",
"resizeMode": "contain",
"backgroundColor": "#ffffff"
},
"assetBundlePatterns": ["**/*", "./assets/fonts/*"],
"ios": {
"supportsTablet": true
},
"android": {
"permissions": ["android.permission.RECORD_AUDIO"],
"adaptiveIcon": {
"foregroundImage": "./assets/adaptive-icon.png",
"backgroundColor": "#ffffff"
},
"package": "com.pitikkuning.LoginApp"
},
"web": {
"favicon": "./assets/favicon.png"
},
"extra": {
"eas": {
"projectId": "hbjqb3biuinrk2j84jjke"
}
},
"plugins": [
[
"expo-av",
{
"microphonePermission": "Allow Voice to Text Tutorial to access the microphone",
"speechRecognitionPermission": "Allow Voice to Text Tutorial to securely recognize user speech"
}
],
[
"@react-native-voice/voice",
{
"microphonePermission": "Allow Voice to Text Tutorial to access the microphone",
"speechRecognitionPermission": "Allow Voice to Text Tutorial to securely recognize user speech"
}
]
]
}
}
package.json :
{
"name": "loginapp",
"version": "1.0.0",
"main": "node_modules/expo/AppEntry.js",
"scripts": {
"start": "expo start",
"android": "expo run:android",
"ios": "expo run:ios",
"web": "expo start --web"
},
"dependencies": {
"@expo/config-plugins": "~7.2.2",
"@react-native-picker/picker": "2.4.10",
"@rneui/base": "^4.0.0-rc.8",
"@rneui/themed": "^4.0.0-rc.8",
"expo": "^49.0.20",
"expo-av": "~13.4.1",
"expo-dev-client": "~2.4.12",
"expo-file-system": "~15.4.5",
"expo-font": "~11.4.0",
"expo-permissions": "~14.2.1",
"expo-speech": "~11.3.0",
"expo-splash-screen": "^0.20.5",
"expo-status-bar": "~1.6.0",
"expo-system-ui": "~2.4.0",
"react": "18.2.0",
"react-native": "0.72.6",
"react-native-reanimated": "~3.3.0",
"react-native-safe-area-context": "4.6.3",
"react-native-vector-icons": "^10.0.2",
"react-native-web": "^0.19.9",
"twrnc": "^3.6.4"
},
"devDependencies": {
"@babel/core": "^7.20.0",
"@babel/plugin-proposal-class-properties": "^7.18.6",
"@react-native-voice/voice": "^3.2.4",
"customize-cra": "^1.0.0",
"react-app-rewired": "^2.2.1"
},
"private": true
}
with the eas.json app.json and package.json configurations as above, I was able to successfully build the application. But when I run the application I don't get the output value from the speech listening process.
useEffect(() => {
Voice.onSpeechError = (error) => setErrorListening(error.error);
Voice.onSpeechResults = (result) => setResultListening(result.value[0]);
Voice.onSpeechStart = () => setListeningSpeech(true);
Voice.onSpeechEnd = () => setListeningSpeech(false);
return () => {
Voice.destroy().then(Voice.removeAllListeners);
};
}, []);
const startListening = async () => {
try {
await Voice.start("en-US");
setListeningSpeech(true);
} catch (error) {
setErrorListening(error);
}
};
const stopListening = async () => {
try {
await Voice.stop();
setListeningSpeech(false);
} catch (error) {
setErrorListening(error);
}
};
Has this been solved? The main issue might be the fact that the linking instructions are outdated? The link command has been deprecated.
I have not got it to work yet, but its been a few days since Ive been able to try. using expo install instead of yarn may have helped.
'compile project' has been deprecated, using 'implementation' instead of 'compile'
Hello, I am using this on a very simple Expo app in a bare workflow. iOS compiles and works fine, however when I
npx expo run:android
oreas build --profile development --platform android
I get the following error:I tried manually linking (but to be honest Im not very familiar with the process), some other people mentioned I needed to change the the node modules: https://stackoverflow.com/questions/23796404/could-not-find-method-compile-for-arguments-gradle
However, Im not really sure to what extent expo alters your iOS and android folders... I also tried install with yarn, npm, and expo install.
If I
npx expo doctor
I get:Which seems to indicate
react-native-expo
is requiring an old version of@expo/config-plugins
:Any help would be much appreciated! I was floored by how well this worked on iOS!
Just for good measure, my
package.json
is below:And I got the following in my
app.json
: