Find article here: https://medium.com/nollie-studio/creating-a-smooth-and-interactive-video-timeline-with-react-native-and-ffmpeg-8c6624ad90ca
- install node dependencies
npm i
-
install android SDK
Install API Android 24 (7.0 Nougat) or higher
Install NDK 22.1.7171670 or higher
Edit the file android/local.properties, in which you will write the local path of the android sdk and the NDK
sdk.dir= local path/Android/Sdk
ndk.dir= local path/Android/Sdk/ndk/22.1.7171670
use '\\' on windows
It's likely that the device is no longer authorized on ADB for whatever reason.
- Check if authorized:
<ANDROID_SDK_HOME>\platform-tools>adb devices
List of devices attached
4df798d76f98cf6d unauthorized
- Revoke USB Debugging on phone
If the device is shown as unauthorized, go to the developer options on the phone and click "Revoke USB debugging authorization"
- Restart ADB Server:
Then restarted adb server
adb kill-server
adb start-server
- Reconnect the device
The device will ask if you are agree to connect the computer id. You need to confirm it.
- Now Check the device
It is now authorized!
adb devices
<ANDROID_SDK_HOME>\platform-tools>adb devices
List of devices attached
4df798d76f98cf6d device
use npm to interactively preview the app on a mobile device or virtual device
npm run android
Write following commands
Linux:
npm run build-android && cd android && ./gradlew assembleDebug
Linux:
npm run build-android && cd android && gradlew.bat assembleDebug
Then You can find your apk here:
app/build/outputs/apk/