将使用Flutter官方提供的github上面的web示例demo运行Web应用。
github下载地址:https://github.com/flutter/samples/tree/master/web
1、下载demo命令:
git clone --depth 1 https://github.com/flutter/samples.git
2、进入web目录
cd web
3、切换分支
flutter channel dev
4、更新SDK(可以不用更新,建议更新下。开发时候在切回到stable即可)
flutter upgrade
5、进入需要运行的目录,如:filipino_cuisine
cd filipino_cuisine
6、初始化项目
flutter packages get
7、在Chrome上运行
flutter run -d chrome

本文详细介绍如何从github下载并运行Flutter官方提供的web示例demo。包括克隆项目、切换分支、更新SDK、初始化项目等步骤,并最终在Chrome浏览器中运行。

1152

被折叠的 条评论
为什么被折叠?



