> For the complete documentation index, see [llms.txt](https://mobile.mrw0l05zyn.cl/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://mobile.mrw0l05zyn.cl/android/analisis-estatico/reversing/aplicaciones-hibridas/react-native.md).

# React Native

## General

Al desarrollar una aplicación con React Native, la mayor parte de la lógica se implementa en JavaScript. El proyecto también incluye clases nativas como MainActivity, escritas en Java o Kotlin, que actúan como punto de entrada en la plataforma Android. Cuando la aplicación está lista para su publicación, el código JavaScript se empaqueta en un archivo optimizado y minificado llamado `index.android.bundle`, lo que mejora el rendimiento y reduce el tamaño total de la aplicación.

* `APK -> Resources-> assets-> index.android.bundle`

## Lectura de código JavaScript minificado

```sh
apktool d application.apk -o app-decompiled

file app-decompiled/assets/index.android.bundle
app-decompiled/assets/index.android.bundle: React Native minified JavaScript, ASCII text

js-beautify app-decompiled/assets/index.android.bundle > output.js
```

## Lectura de código JavaScript compilado (Hermes)

```sh
apktool d application.apk -o app-decompiled

file app-decompiled/assets/index.android.bundle
app-decompiled/assets/index.android.bundle: Hermes JavaScript bytecode

# hermes-dec
./hbc_decompiler.py app-decompiled/assets/index.android.bundle output.js
```

## Herramientas

* [js-beautify](https://github.com/beautifier/js-beautify)
* [hermes-dec](https://github.com/P1sec/hermes-dec)


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://mobile.mrw0l05zyn.cl/android/analisis-estatico/reversing/aplicaciones-hibridas/react-native.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
