草庐IT

android - 如何为 React Native 的 64 位版本准备我的应用程序?

这是我的build.gradle:applyplugin:"com.android.application"importcom.android.build.OutputFile/***Thereact.gradlefileregistersataskforeachbuildvariant(e.g.bundleDebugJsAndAssets*andbundleReleaseJsAndAssets).*Thesebasicallycall`react-nativebundle`withthecorrectargumentsduringtheAndroidbuild*cycle.Bydef

android - 在 Android Nexus 5 设备上 react native 开发菜单

我有一个基本的react-native我在真正的Nexus5上运行的应用程序,我找不到启用开发人员菜单的方法,该菜单为iOS提供和模拟设备。https://facebook.github.io/react-native/docs/debugging.htmlhttps://facebook.github.io/react-native/docs/running-on-device.htmlMethod1:Usingadbreverse(recommended)YoucanusethismethodifyourdeviceisrunningAndroid5.0(Lollipop),ith

android - 如何设计兼容所有设备的 React Native 屏幕

我正在尝试设计这个设计react-native。这是我为此编写的代码,但这不是我想要的。这仅适用于一个屏幕,如果我更改屏幕尺寸则无法正常工作。这看起来像绝对布局。我应该做哪些更改才能使其适用于所有屏幕尺寸。/***SampleReactNativeApp*https://github.com/facebook/react-native*@flow*/importReact,{Component}from"react";import{AppRegistry,Image,View,Text,Button,StyleSheet}from"react-native";classSplashSc

android - React Native 任​​务 ':app:transformClassesWithDexForDebug' 执行失败

我是reactnative的新手,我在Ubuntu中使用它。我想在我的电脑上运行一个项目。我使用yarn和安卓模拟器。这是我安装的应用程序版本:yarn:1.2.0nmp:3.10.10我在使用时遇到了以下错误:$react-nativerun-android这里是错误:*Whatwentwrong:Executionfailedfortask':app:transformClassesWithDexForDebug'.>com.android.build.api.transform.TransformException:com.android.ide.common.process.P

android - 如何在 Java 中使用 appium 为 android native 应用程序执行滑动

我需要滑动我的应用程序(从左到右和从右到左),而我在appium中使用Java来实现androidnative应用程序自动化。我试过这个链接,Swipemethodnotworkinginandroidautomationtesting但我不能,请分享任何其他链接或任何人帮助我。 最佳答案 这是我们的做法-向左滑动-appiumDriver.context("NATIVE_APP");Dimensionsize=appiumDriver.manage().window().getSize();intstartx=(int)(size

android - 意外的顶级异常( react native )

我在构建我的项目时遇到了这个错误,它是一个react-nativeandroid项目:UNEXPECTEDTOP-LEVELEXCEPTION:com.android.dex.DexException:MultipledexfilesdefineLandroid/support/v7/app/ActionBar$Callback;atcom.android.dx.merge.DexMerger.readSortableTypes(DexMerger.java:594)atcom.android.dx.merge.DexMerger.getSortedTypes(DexMerger.ja

android - ionic 3 native : File : {code: 5, 消息: "ENCODING_ERR"}

我正在使用checkFilefunctionfromFileAPIplugin在Ionic3中检查文件是否存在于本地。Promise拒绝并出现以下错误:FileError{code:5,message:"ENCODING_ERR"}从我在MozillaDocsoftheFileAPI上看到的,问题是“URL格式不正确”。但是,我看不出URL是如何格式错误的。这是显示我如何调用函数的相关代码以及所涉及变量的实际值(baseDirectory的值设置为file:///data/user/0/ch.protectator.fehpedia/文件/):letbaseDirectory=this

android - 无法运行 React-Native UIExplorer 示例项目

我一直在尝试在Windows上运行UIExplorer项目。我收到以下错误-......make:***[D:\react-native\ReactAndroid\build\tmp\buildReactNdkLib/local/armeabi-v7a/objs/reactnativejni/JExecutorToken.o]Error2......Whatwentwrong:Executionfailedfortask':ReactAndroid:buildReactNdkLib'.>Process'command'C:\android-ndk-r11b\ndk-build.cmd'

android - React native - 不断添加 android.permission.READ_PHONE_STATE

我的应用程序不需要读取手机状态,所以我想从我的Reactnative应用程序中删除权限。每次我从项目的任何地方删除它时,当我运行./gradlewassembleRelease时它会再次重新添加如何让它停止添加? 最佳答案 使用androidlist合并添加新文件android/app/src/release/AndroidManifest.xml有内容完成!有关list合并的更多信息:https://developer.android.com/studio/build/manifest-merge.html#merge_prior

android - React Native 中的状态栏颜色

如何更改StatusBar的背景颜色来自react-native的组件,无需编辑Android特定文件?文档says,我可以使用backgroundColor属性(property)。但它失败了。barStyle属性,setBarStyle&&setBackgroundColor静态方法也不能正常工作。只有hidden属性有效。我正在使用create-react-native-app,用Expobuild. 最佳答案 在ExpoApp中,您需要像这样在项目根目录中编辑app.json:{"expo":{"sdkVersion":"1