草庐IT

android - 使用 Android App Bundle 来减小 react-native apk 的大小

有没有办法使用AndroidAppBundle来减小android应用程序的大小,并在react-native项目中按需交付功能? 最佳答案 最近的拉取请求增加了对AndroidAppBundle的支持https://github.com/facebook/react-native/pull/23239它没有很好的文档记录,但如果您进行必要的更改,它会起作用。引用资料:https://github.com/react-native-community/releases/issues/91https://developer.andro

android - 发布前报告 "Issue: native crash"

GooglePlay控制台发布前报告指出我的应用程序在PixelAndroid8.0上运行时发生崩溃(其他应用程序没有问题)。观看回放时,我没有发现任何问题,也没有看到应用程序崩溃。这是提供的信息。Issue:Nativecrashofcom.xxxxxxxxxBuildfingerprint:'google/sailfish/sailfish:8.0.0/OPR3.170623.008/4294783:user/release-keys'Revision:'0'ABI:'arm64'pid:10010,tid:10046,name:ControllerMesse>>>com.xxxx

android - Expo - 网络响应超时错误 (create-react-native-app) (Windows 10)

我遇到了与此处完全相同的问题:NetworkResponseTimeOutError(create-react-native-app)(expo).每次我尝试通过局域网中的手机扫描二维码时,都会出现网络响应超时错误。我已经查看了链接的stackoverflow帖子和相关的github线程中的每一个响应:https://github.com/react-community/create-react-native-app/issues/144#issuecomment-296631692无济于事。我已经尝试过的一切用我的静态ip设置REACT_NATIVE_PACKAGER_HOSTNAM

android - 如何将 Shrinker (R8) 与 react-native 一起使用

我正在将react-native版本更新到0.60.4,但是当我尝试构建版本时,我陷入了Task:app:transformClassesAndResourcesWithR8ForRelease我试过禁用R8并且可以正常工作,但得到了3倍大的apkR8isthenewAndroidcodeshrinker.Ifyouexperienceanyissues,pleasefileabugathttps://issuetracker.google.com,using'Shrinker(R8)'ascomponentname.YoucandisableR8byupdatinggradle.pr

如何在React Native中提交表格

我在这里问这个问题很疯狂,但我找不到任何关于如何提交表格并捕获RN的数据的好教程。我发现的一切都是有人推图书馆“只需npm安装反应形式-基因-基因-魔术盒,然后将其称为您的项目"...但是我只想知道-如何在香草中提交表格反应天然.示例代码:authcontainerclassAuthContainerextendsComponent{render(){const{errorMessage,handleLogin}=this.propsreturn(handleLogin(e)}/>)}}.....constmapDispatchToProps=(dispatch)=>{return{handl

Android - native 层的 VPN

只是一个简短的问题,因为Google并没有吐出太多东西。是否可以使用native代码创建VPN连接安卓?如果是这样,VPN是否提供对保持Activity的支持? 最佳答案 我认为这更像是一个权限问题,而不是暴露或未暴露的问题。大多数VPN连接需要您修改和访问内核的网络过滤调用。由于您的应用程序真的应该在它自己的沙箱中运行,所以我怀疑这是默认情况下(至少对应用程序)公开的东西,因为您实际上是在修改整个操作系统路由网络流量的方式。出于同样的原因,为了在操作系统中修改iptables,它需要被root,这样你的应用程序才能真正改变这些东西

android - React Native 与现有应用程序集成崩溃 : "Can' t find variable: __fbBatchedBridge"

我通过Facebook指南将ReactNative与AndroidStudio中的现有应用集成:http://facebook.github.io/react-native/docs/embedded-app-android.html#content我发现“Can'tfindvariable:__fbBatchedBridge”的错误可以通过设置dev菜单来解决。就像ReferenceError:Can'tfindvariable:__fbBatchedBridge但我的问题是我在现有应用程序的Activity中显示了ReactNative页面,当使用ReactNativeView启动

android - React native + Appium,如何找到一个元素

我正在尝试(太长时间......)让appium与ReactNative一起工作,但似乎找不到任何元素。我正在使用模拟器、Nexus6、android6.0、ubuntu、appium1.6.0、RN0.39.2。我正在尝试让最基本的示例起作用://foo.jsrender(){return(foo)}//spec.js//...somesetup...driver.elementByAccessibilityId('foo').click()我正在……1)shouldbeabletofind'Buttons'andclickit0passing(13s)1failing1)Andro

android - 如何在 CMakeLists.txt 文件中获取 android 构建类型(调试、发布)作为变量,以便在 android studio 中进行外部 native 构建?

我需要将android构建类型(调试、发布)引用到用于构建外部native库的CMakeLists.txt文件中。更确切地说:set_target_properties(#Specifiesthetargetlibrary.mylibname#Specifiestheparameteryouwanttodefine.PROPERTIESIMPORTED_LOCATION#Providesthepathtothelibraryyouwanttoimport.$ENV{LIBRARY_HOME}/${ANDROID_BUILD_TYPE}/libs/${ANDROID_ABI}/libMy

javascript - React native,添加 Root View 时出错

我一直在尝试在我的项目中使用“react-native-popup”,渲染弹出窗口时在红屏中出现以下错误。如果我重新加载,该消息将被视为警告,应用程序运行正常,但错误消息偶尔会出现。我想知道这是什么问题?Tryingtoaddarootviewwithanexplicitidalreadyset.ReactNativeusestheidfieldtotrackreacttagsandwilloverwritethisfield.Ifthatisfine,explicitlyoverwritetheidfieldtoView.NO_IDbeforecallingaddMeasuredRo