我想在flutter中开发支持测试版的web应用程序。因此,我通过CLI在flutter配置中启用了web,如下所示。
$ flutter config --enable-web
WARNING: cgroup v2 is not fully supported yet, proceeding with partial confinement
Setting "enable-web" value to "true".
You may need to restart any open editors for them to read new settings.
作为开发过程中的下一步,我想检查浏览器是否作为带有flutter的设备连接,但它不是
$ flutter devices
WARNING: cgroup v2 is not fully supported yet, proceeding with partial confinement
No devices detected.
因此,我交叉验证了flutter配置,它显示了启用的web状态
$ flutter config
...
Settings:
enable-web: true (Unavailable)
为什么启用web show为true,但不可用?如何将web浏览器连接为处于颤动状态的设备
您目前处于颤振的稳定通道上。Flutter目前只支持测试版和更高版本。您可以更改为测试版并启用以下web支持:
flutter channel beta
flutter upgrade
flutter config --enable-web
源