React native 环境
来源:互联网 发布:远程语音软件 编辑:程序博客网 时间:2024/06/06 00:31
-------------------------------------------------------------------------------react native 环境搭建---------------------------------------------------------------
一、安装包管理器
注意:时间稍微长点 @powershell -NoProfile -ExecutionPolicyBypass -Command "iex ((new-objectnet.webclient).DownloadString('https://chocolatey.org/install.ps1'))"&& SET PATH=%PATH%;%ALLUSERSPROFILE%\chocolatey\bin
二、安装python 2
choco install python2
choco install python2– n 跳过
三、设置镜像
npm config setregistry https://registry.npm.taobao.org --global
npm config setdisturl https://npm.taobao.org/dist --global
四、安装react-native命令行工具
npm install -greact-native-cli
yarn facebook提供的npm管理工具
npm install -g yarnreact-native-cli
五、创建项目
注意:时间较长
react-native initMyProject
react-native initAwesomeProject
六、运行(Packager
react-nativestart
注意:碰到了ERROR Watchertook too long to load的报错,请尝试将这个文件中的MAX_WAIT_TIME值改得更大一些 (文件在node_modules/react-native/目录下)。
七、查看打包脚本
http://localhost:8081/index.android.bundle?platform=android
八、运行android
react-native run-android
九、调试
打开Chrome 浏览器 F12打开开发者模式
React-native start 更新
十、2
十一、 react-native bundle --platformandroid --dev false --entry-file index.android.js --bundle-outputandroid/app/src/main/assets/index.android.bundle --assets-destandroid/app/src/main/res
十二、 daba
gradle assembleDebug
- React Native环境搭建
- React Native 环境配置
- react native环境搭建
- React Native环境配置
- React-Native环境配置
- React Native 环境配置
- react-native环境搭建
- React Native 环境配置
- React Native环境搭建
- React Native环境搭建
- React Native环境搭建
- React-native 环境搭建
- React Native 环境搭建
- React Native环境配置
- react-native:环境安装
- React Native环境搭建
- React Native环境搭建
- React Native环境搭建
- 遗传算法 与旅行商问题
- Siri真的要离开我们了?
- poj 2262(水题)
- BAT批处理定期删除清理指定N天前的文件
- 大型网站架构演化过程
- React native 环境
- Python3.X之函数式编程笔记
- A quick-and-dirty audio sample mixing technique to avoid clipping
- 定义宏可以方便地访问stl容器
- MyISAM 和InnoDB
- mac php5.6+oci8+pdo_oci扩展
- linux的一些基本命令(关于文件操作, 进程操作,以及/boot问题)
- 《Spring揭秘》笔记——Spring中两种容器比较
- PHP