Error: spawnSync ./gradlew EACCES React Native Error Fix

I was trying to run one of my react native projects on the Android emulator and faced the following error. Error: spawnSync ./gradlew EACCES at Object.spawnSync (internal/child_process.js:1041:20) at spawnSync (child_process.js:607:24) at execFileSync (child_process.js:634:15) at runOnAllDevices (/home/rashid/Desktop/React Native/Tomorrow/node_modules/@react-native-community/cli-platform-android/build/commands/runAndroid/runOnAllDevices.js:74:39) at buildAndRun (/home/rashid/Desktop/React Native/Tomorrow/node_modules/@react-native-community/cli-platform-android/build/commands/runAndroid/index.js:158:41) at /home/rashid/Desktop/React Native/Tomorrow/node_modules/@react-native-community/cli-platform-android/build/commands/runAndroid/index.js:125:12 at processTicksAndRejections (internal/process/task_queues.js:85:5) at async Command.handleAction (/home/rashid/Desktop/React Native/Tomorrow/node_modules/react-native/node_modules/@react-native-community/cli/build/cliEntry.js:160:7) My PC runs…

Error: spawnSync ./gradlew EACCES React Native Error Fix

I was trying to run one of my react native projects on the Android emulator and faced the following error. Error: spawnSync ./gradlew EACCES at Object.spawnSync (internal/child_process.js:1041:20) at spawnSync (child_process.js:607:24) at execFileSync (child_process.js:634:15) at runOnAllDevices (/home/rashid/Desktop/React Native/Tomorrow/node_modules/@react-native-community/cli-platform-android/build/commands/runAndroid/runOnAllDevices.js:74:39) at buildAndRun (/home/rashid/Desktop/React Native/Tomorrow/node_modules/@react-native-community/cli-platform-android/build/commands/runAndroid/index.js:158:41) at /home/rashid/Desktop/React Native/Tomorrow/node_modules/@react-native-community/cli-platform-android/build/commands/runAndroid/index.js:125:12 at processTicksAndRejections (internal/process/task_queues.js:85:5) at async Command.handleAction (/home/rashid/Desktop/React Native/Tomorrow/node_modules/react-native/node_modules/@react-native-community/cli/build/cliEntry.js:160:7) My PC runs…

How to specify Height and Width in Percent with respect to the screen in Flutter

Mobile phone devices are of various sizes and resolutions. Developing a mobile app that looks similar to all these phones is not easy. In such cases, mentioning height and width in percent with respect to the screen can help you. In Flutter, you can’t really specify some percent of width or height directly. You can…

How to Detect React Native App is in Background

Sometimes, you may want to know whether your react native app is running background or running foreground to execute your tasks. You can use the AppState API from react native for this purpose. If the AppState.currentState is active then it means your app is running in the foreground whereas if the AppState.currentState is background then…

Stuck at Installing build\app\outputs\apk\app.apk… Flutter Issue Fix

Sometimes, when you run your Flutter project you may come across this particular Flutter issue- you get stuck at Launching lib/main.dart on XT1635 02 in debug mode… Built build/app/outputs/apk/debug/app-debug.apk… You may even wait for many minutes and your app wouldn’t start on your Android device. So, how to fix this Flutter issue? All you need…

You need to have compileSdk set to at least 28 in your module build.gradle to migrate to AndroidX Flutter Issue Fix

You may face this Flutter AndroidX error when you try to migrate your Flutter project to AndroidX. In Android Studio, you would come across a dialog box saying: You need to have compileSdk set to at least 28 in your module build.gradle to migrate to AndroidX So, how to fix this Flutter issue? Open the…

How to use BackHandler with React Navigation in React Native

On Android devices, users prefer the hardware back button to navigate back. Even though the actions of the back button are generally desirable, sometimes you may need to customize the action of the hardware button. In this blog post, Let’s see how to customize the back button actions using BackHandler and react-navigation library. The BackHandler…