react native
君归乐
这个作者很懒,什么都没留下…
展开
-
/(.*\\__fixtures__\\.*|node_modules[\\\]react[\\\]dist[\\\].*|website\\node_modules\\.解决方法
原因小编在运行react-native (0.59)版本的时候,运行js文件的时候报出这个错误出来。Invalid regular expression: /(.\fixtures\.|node_modules[\]react[\]dist[\].|website\node_modules\.|heapCapture\bundle.js|.\tests\.)$/: Unterminated character class. Run CLI with --verbose flag for more det原创 2020-09-17 14:15:14 · 909 阅读 · 0 评论 -
react-native进行android系统app版本提示更新(无需后端接口)跳转到对应Google Play下载页
1.react native要想实现无需后端接口获取app版本信息要用到cheerio请点击 react native通过cheerio抓取google play商店里面app的版本号2.使用版本号进行对比提示更新import {Linking} from 'react-native';//设备信息import DeviceInfo from 'react-native-device-info';import cheerio from 'cheerio'; componentDidMount原创 2020-09-10 16:26:07 · 1055 阅读 · 0 评论 -
react-native进行ios系统app版本提示更新(无需后端接口)跳转到App Store
import {Linking} from 'react-native';//设备信息import DeviceInfo from 'react-native-device-info'; componentDidMount() { this._getVersion(); } // 检查app更新 _getVersion(){ let bundleId = "ios的bundleId"//ios的bundleId return fet原创 2020-09-10 16:08:38 · 1561 阅读 · 0 评论 -
react native通过cheerio抓取google play商店里面app的版本号
cheerio快速、灵活、精益的实现了为服务器设计的核心jquery安装yarn add cheerio@0.22.0yarn add events stream buffer使用cheerio获取版本号async getVersion(){ let appid = "你app的applicationId"; const response = await fetch(`https://play.google.com/store/apps/details?id=${appid}&原创 2020-09-10 15:34:38 · 600 阅读 · 0 评论 -
React Native解决在禁用ios13暗黑模式下状态栏的字体颜色为白色的问题(RN的0.59.10版本)
React Native解决在禁用ios13暗黑模式下状态栏的字体颜色为白色的问题使用react-native禁用ios13暗黑模式后,在页面背景颜色是白色的情况下,状态栏的颜色还是暗黑模式的白色字体,会导致我们看不见状态栏的信息。小编使用的是react-native的0.59.10版本(据说最新版本的已经不存在这个问题)解决方案在依赖文件夹下node_modules/react-native/React/Modules/RCTStatusBarManager.mRCT_ENUM_CONVER原创 2020-07-28 09:05:09 · 1214 阅读 · 0 评论 -
解决react-native-datepicker在 ios的深色模式下 日期选择时透明看不见的问题
react-native-datepicker在ios的深色模式下会导致,透明看不见的问题解决方案app禁用ios的深色模式:即ios在深色模式下使用app依然使用这ios浅色模式下的效果在Info.plist中增加User Interface Style,值为Light,如下再次运行就解决了...原创 2020-07-06 14:18:03 · 794 阅读 · 0 评论 -
React-Native搭建报错:index.android.bundle is packaged correctly for release
React-Native搭建启动后报错:Unable to load script.Make sure you're either running a metro server(run 'react-native start' ) or that your bundle 'index.android.bundle' is packaged correctly for release.原因是:在根目录android/app/src/main/assets/index.android.bundle没有原创 2020-05-23 01:38:59 · 1245 阅读 · 0 评论 -
解决react-native启动后无法热更新Reload JS/Reload出现The development server returned response error code: 404
解决react-native启动后无法热更新Reload JS首先在手机摇一摇调试出开发者菜单中选择 Reload就会报错:The development server returned response error code: 404那么很有可能是8081的端口被占用了netstat -aon|findstr "8081"然后再执行taskkill /f /pid 17976 终止进程taskkill /f /pid 17976再继续观察端口占用情况最后:yarn andro原创 2020-05-23 01:29:49 · 1421 阅读 · 0 评论 -
react-native编译时报react-native-community/masked-view 错
当react-native项目编译时遇到react-native-community/masked-view 错react-navigation问题例如:Error: undefined Unable to resolve module @react-native-community/ masked-view from 'node modules\react-naviqation-stack...原创 2020-01-23 22:04:35 · 4843 阅读 · 0 评论 -
Unable to load script.Make sure you're either running a metro server (run 'react-native start' )
遇到的问题当react-native run-android运行时打开遇到Unable to load script.Make sure you’re either running a metro server (run ‘react-native start’ )解决方案在创建的项目目录/android/app/build.gradle里修改这样在重新运行就可以正常打开了...原创 2020-01-20 11:54:07 · 1968 阅读 · 3 评论 -
react native与夜神模拟器结合使用运行安卓平台
react native与夜神模拟器结合使用前提准备React Native 与 夜神模拟器连接还有一些坑前提准备JDKPython 2nodeSDKReact Native 与 夜神模拟器连接首先adb连接到夜神模拟器上。命令行 adb devices直接运行adb devices如果什么都没有。就需要启动模拟器,然后进入夜神安装目录的bin目录下。D:\Program F...原创 2020-01-20 11:25:26 · 422 阅读 · 1 评论