安卓开发环境搭建

chocolatey

官网

https://www.chocolatey.org/install

安装(powershell)

Set-ExecutionPolicy Bypass -Scope Process -Force; [System.Net.ServicePointManager]::SecurityProtocol = [System.Net.ServicePointManager]::SecurityProtocol -bor 3072; iex ((New-Object System.Net.WebClient).DownloadString('https://chocolatey.org/install.ps1'))

dart

官网

https://www.dartcn.com/

安装dart-sdk

choco install dart-sdk

flutter

官网

https://flutter.dev/

安装

官网下载安装包,解压至D盘,获取bin目录,添加至path系统变量中

验证安装是否成功

flutter

检查flutter开发环境

flutter doctor

创建flutter_app

flutter create flutter_app
cd flutter_app
flutter run

flutter遇到问题

flutter create 进程较慢

参考https://blog.csdn.net/huanggan08/article/details/88641198

set PUB_HOSTED_URL=https://pub.flutter-io.cn
set FLUTTER_STORAGE_BASE_URL=https://storage.flutter-io.cn

flutter run 进程较慢,长时间卡在Running Gradle task 'assembleDebug'...

windows参考https://segmentfault.com/a/1190000021451897?utm_source=tag-newest

maven { url 'https://maven.aliyun.com/repository/google' }
maven { url 'https://maven.aliyun.com/repository/jcenter' }
maven { url 'http://maven.aliyun.com/nexus/content/groups/public' }
修改build.gradle
image.png
修改D:\flutter\packages\flutter_tools\gradle\flutter.gradle
image.png

react-native

官网

https://reactnative.cn/

安装nrm

npm install -g nrm

安装nodejs

https://nodejs.org/en/

安装python2

https://www.python.org/downloads/release/python-2717/

安装JDK

https://www.oracle.com/technetwork/java/javase/downloads/jdk8-downloads-2133151.html

安装android-studio

https://reactnative.cn/docs/getting-started.html

新建app

npx react-native init AwesomeProject
cd ./AwesomeProject
npm run android
最后编辑于
©著作权归作者所有,转载或内容合作请联系作者
【社区内容提示】社区部分内容疑似由AI辅助生成,浏览时请结合常识与多方信息审慎甄别。
平台声明:文章内容(如有图片或视频亦包括在内)由作者上传并发布,文章内容仅代表作者本人观点,简书系信息发布平台,仅提供信息存储服务。

友情链接更多精彩内容