如何为生产构建 React Native android 应用程序? [英] How to build react native android app for production?

查看:30
本文介绍了如何为生产构建 React Native android 应用程序?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我已经看到了适用于 android 的 React Native 的新版本并尝试了一些示例.它仅适用于 USB 调试模式和adb reverse tcp:8081 tcp:8081".如何为生产"构建 android 应用程序,包括所有依赖项并且没有反应网络服务器连接.谢谢.

I've seen new release of react native for android and tried some examples. It works only with USB debug mode and "adb reverse tcp:8081 tcp:8081". How can I build android app for "production" including all dependencies and without react web-server connections. Thank you.

推荐答案

要构建 Android 应用的发布版本:

To build a release version of your Android app:

$ cd your-app-folder
$ cd android && ./gradlew assembleRelease

您需要为 Play 商店设置签名密钥,完整文档在此:http://facebook.github.io/react-native/docs/signed-apk-android.html

You'll need to set up signing keys for the Play Store, full documentation here: http://facebook.github.io/react-native/docs/signed-apk-android.html

这篇关于如何为生产构建 React Native android 应用程序?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆