web_shell_flutter/README.md

29 lines
739 B
Markdown
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

# web_android_shell
H5 壳子项目。
## 调试说明
这个项目在部分设备上,如果直接用 `Ctrl+C` 结束 `flutter run`,设备里的上一次 App 进程可能还留在后台,下一次运行时会影响内嵌 WebView 启动。
更稳的做法:
- 调试结束时优先在 `flutter run` 里按 `q`
- 或者使用项目自带脚本,先自动杀掉旧进程再启动
```powershell
.\tool\flutter_run_fresh.ps1
```
如果要指定设备,也可以继续透传给 `flutter run`
```powershell
.\tool\flutter_run_fresh.ps1 -d F136A
```
脚本会自动:
- 读取 `android/local.properties` 中的 `sdk.dir`
- 调用 `adb shell am force-stop com.yuanxuan.webshell.web_android_shell`
- 然后执行 `flutter run`