expo-dev-menu
TypeScript icon, indicating that this package has built-in type declarations

4.5.8 • Public • Published

📦 expo-dev-menu

Expo/React Native module to add developer menu to Debug builds of your application. This package is intended to be included in your project through expo-dev-client.

Documentation

You can find more information in the Expo documentation.

Contributing

The expo-dev-menu repository consists of two different parts, the exported package, which includes the native functions, located in the android, ios and src folders and the Dev Menu interface, located under the app folder.

Local development is usually done through bare-expo.

First, make sure to yarn and yarn start in expo-dev-menu which will add the port for the dev menu packager to dev-menu-packager-host. This is bundled into the native code in bare-expo so need to be done first.

To use dev-client when running bare-expo on Android, open MainApplication.java and set the USE_DEV_CLIENT value to true.

- static final boolean USE_DEV_CLIENT = false;
+ static final boolean USE_DEV_CLIENT = true;

To use dev-client when running bare-expo on iOS, open AppDelegate.mm and set the USE_DEV_CLIENT value to YES.

- BOOL useDevClient = NO;
+ BOOL useDevClient = YES;

Then build the native apps with npx pod-install && yarn ios or yarn android.

Making JavaScript changes inside the app folder

To update the JavaScript code inside the app folder, you need to run the dev-menu bundler locally.

  1. Navigate to the dev-menu package: cd packages/expo-dev-menu
  2. Start the Metro bundler: yarn start
  3. To use your local bundler on Android, open DevMenuHost.java and set getUseDeveloperSupport to true.
- override fun getUseDeveloperSupport() = false
+ override fun getUseDeveloperSupport() = true
  1. Play with your changes on a simulator or device through bare-expo
  2. Once you've made all the necessary changes run yarn bundle:prod:ios && yarn bundle:prod:android to update the embedded bundle

Dependencies (2)

Dev Dependencies (15)

Package Sidebar

Install

npm i expo-dev-menu

Weekly Downloads

209,533

Version

4.5.8

License

MIT

Unpacked Size

5.88 MB

Total Files

528

Last publish

Collaborators

  • szdziedzic
  • alanhughes
  • kadikraman
  • radoslawkrzemien
  • aleqsio
  • marklawlor
  • gabrieldonadel
  • simek
  • keith-kurak
  • christopherwalter
  • kbrandwijk
  • fiber-god
  • ide
  • brentvatne
  • evanbacon
  • quinlanj
  • expoadmin
  • tsapeta
  • exponent
  • wschurman
  • wkozyra
  • bycedric
  • lukmccall
  • jonsamp
  • princefleaswallow
  • kudochien