Skip to content

Commit

Permalink
Update EmbeddedAppAndroid.md
Browse files Browse the repository at this point in the history
  • Loading branch information
mkonicek committed Nov 7, 2015
1 parent 1f0566f commit 0bcd01e
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions docs/EmbeddedAppAndroid.md
Original file line number Diff line number Diff line change
Expand Up @@ -167,3 +167,7 @@ To run your app, you need to first start the development server. To do this, sim
Now build and run your Android app as normal (e.g. `./gradlew installDebug`). Once you reach your React-powered activity inside the app, it should load the JavaScript code from the development server and display:

![Screenshot](/react-native/img/EmbeddedAppAndroid.png)

## Sharing a ReactInstance across multiple Activities / Fragments in your app

You can have multiple Activities or Fragments that use the same `ReactInstanceManager`. You'll want to make your own "ReactFragment" or "ReactActivity" and have a singleton "holder" that holds a `ReactInstanceManager`. When you need the `ReactInstanceManager` / hook up the `ReactInstanceManager` to the lifecycle of those Activities or Fragments, use the one provided by the singleton.

0 comments on commit 0bcd01e

Please sign in to comment.