(Translated by https://www.hiragana.jp/)
GitHub - jmp/react-native-bundle-extractor: A utility for extracting the React Native JavaScript bundle from an Android APK or a package installed on a connected device.
Skip to content

A utility for extracting the React Native JavaScript bundle from an Android APK or a package installed on a connected device.

License

Notifications You must be signed in to change notification settings

jmp/react-native-bundle-extractor

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

react-native-bundle-extractor

codecov

This is a small utility for extracting the React Native JavaScript bundle file from an Android APK. It can fetch the bundle either from an APK file on the disk, or from an Android package installed on a connected device (including Android virtual devices), without requiring deep knowledge of the Android Debug Bridge (ADB).

Since React Native JavaScript bundles are typically minified, the tool also runs it through jsbeautifier to get a more human-readable output.

The purpose of this tool is to give you a better idea of what your release code will look like. It may convince you to obfuscate your JavaScript bundles.

Installation

pip install -r requirements.txt

Python 3.8 or later is recommended.

Usage

To extract the bundle from an APK:

python extract.py foo.apk

To extract the bundle from connected device using adb:

python extract.py com.package.someapp

To customize the bundle filename, you can pass an additional parameter:

python extract.py com.package.someapp --bundle index.android.bundle

Run tests

pytest

About

A utility for extracting the React Native JavaScript bundle from an Android APK or a package installed on a connected device.

Topics

Resources

License

Stars

Watchers

Forks

Languages